Skip to content

Commit

Permalink
Updated tests and vignettes so R CMD CHECK passing
Browse files Browse the repository at this point in the history
  • Loading branch information
fontikar committed Dec 16, 2024
1 parent c0827ba commit 00ea80f
Show file tree
Hide file tree
Showing 14 changed files with 1,040 additions and 57 deletions.
2 changes: 1 addition & 1 deletion DESCRIPTION
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ Description: What the package does (one paragraph).
License: MIT + file LICENSE
Encoding: UTF-8
Roxygen: list(markdown = TRUE)
RoxygenNote: 7.2.3
RoxygenNote: 7.3.2
Biarch: true
Depends:
R (>= 3.4.0)
Expand Down
9 changes: 6 additions & 3 deletions R/bmsma-package.R
Original file line number Diff line number Diff line change
@@ -1,8 +1,6 @@
#' The 'bmsma' package.
#'
#' @description A DESCRIPTION OF THE PACKAGE
#'
#' @docType package
#' @name bmsma-package
#' @aliases bmsma
#' @useDynLib bmsma, .registration = TRUE
Expand All @@ -14,5 +12,10 @@
#'
#' @references
#' Stan Development Team (NA). RStan: the R interface to Stan. R package version 2.26.23. https://mc-stan.org
#'

#' @keywords internal
"_PACKAGE"

## usethis namespace: start
## usethis namespace: end
NULL
3 changes: 2 additions & 1 deletion R/stanmodels.R
Original file line number Diff line number Diff line change
@@ -1,9 +1,10 @@
# Generated by rstantools. Do not edit by hand.

# names of stan models
stanmodels <- c("bsma", "ols")
stanmodels <- c("bmsma", "bsma", "ols")

# load each stan module
Rcpp::loadModule("stan_fit4bmsma_mod", what = TRUE)
Rcpp::loadModule("stan_fit4bsma_mod", what = TRUE)
Rcpp::loadModule("stan_fit4ols_mod", what = TRUE)

Expand Down
29 changes: 29 additions & 0 deletions man/bmsma-package.Rd

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion man/rmot_assign_data.Rd → man/bmsma_assign_data.Rd

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion man/rmot_model.Rd → man/bmsma_model.Rd

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion man/rmot_run.Rd → man/bmsma_run.Rd

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

13 changes: 0 additions & 13 deletions man/rmot-package.Rd

This file was deleted.

2 changes: 2 additions & 0 deletions src/RcppExports.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -12,10 +12,12 @@ Rcpp::Rostream<false>& Rcpp::Rcerr = Rcpp::Rcpp_cerr_get();
#endif


RcppExport SEXP _rcpp_module_boot_stan_fit4bmsma_mod();
RcppExport SEXP _rcpp_module_boot_stan_fit4bsma_mod();
RcppExport SEXP _rcpp_module_boot_stan_fit4ols_mod();

static const R_CallMethodDef CallEntries[] = {
{"_rcpp_module_boot_stan_fit4bmsma_mod", (DL_FUNC) &_rcpp_module_boot_stan_fit4bmsma_mod, 0},
{"_rcpp_module_boot_stan_fit4bsma_mod", (DL_FUNC) &_rcpp_module_boot_stan_fit4bsma_mod, 0},
{"_rcpp_module_boot_stan_fit4ols_mod", (DL_FUNC) &_rcpp_module_boot_stan_fit4ols_mod, 0},
{NULL, NULL, 0}
Expand Down
32 changes: 32 additions & 0 deletions src/stanExports_bmsma.cc
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
// Generated by rstantools. Do not edit by hand.

#include <Rcpp.h>
using namespace Rcpp ;
#include "stanExports_bmsma.h"

RCPP_MODULE(stan_fit4bmsma_mod) {


class_<rstan::stan_fit<stan_model, boost::random::ecuyer1988> >("rstantools_model_bmsma")

.constructor<SEXP,SEXP,SEXP>()


.method("call_sampler", &rstan::stan_fit<stan_model, boost::random::ecuyer1988> ::call_sampler)
.method("param_names", &rstan::stan_fit<stan_model, boost::random::ecuyer1988> ::param_names)
.method("param_names_oi", &rstan::stan_fit<stan_model, boost::random::ecuyer1988> ::param_names_oi)
.method("param_fnames_oi", &rstan::stan_fit<stan_model, boost::random::ecuyer1988> ::param_fnames_oi)
.method("param_dims", &rstan::stan_fit<stan_model, boost::random::ecuyer1988> ::param_dims)
.method("param_dims_oi", &rstan::stan_fit<stan_model, boost::random::ecuyer1988> ::param_dims_oi)
.method("update_param_oi", &rstan::stan_fit<stan_model, boost::random::ecuyer1988> ::update_param_oi)
.method("param_oi_tidx", &rstan::stan_fit<stan_model, boost::random::ecuyer1988> ::param_oi_tidx)
.method("grad_log_prob", &rstan::stan_fit<stan_model, boost::random::ecuyer1988> ::grad_log_prob)
.method("log_prob", &rstan::stan_fit<stan_model, boost::random::ecuyer1988> ::log_prob)
.method("unconstrain_pars", &rstan::stan_fit<stan_model, boost::random::ecuyer1988> ::unconstrain_pars)
.method("constrain_pars", &rstan::stan_fit<stan_model, boost::random::ecuyer1988> ::constrain_pars)
.method("num_pars_unconstrained", &rstan::stan_fit<stan_model, boost::random::ecuyer1988> ::num_pars_unconstrained)
.method("unconstrained_param_names", &rstan::stan_fit<stan_model, boost::random::ecuyer1988> ::unconstrained_param_names)
.method("constrained_param_names", &rstan::stan_fit<stan_model, boost::random::ecuyer1988> ::constrained_param_names)
.method("standalone_gqs", &rstan::stan_fit<stan_model, boost::random::ecuyer1988> ::standalone_gqs)
;
}
Loading

0 comments on commit 00ea80f

Please sign in to comment.