From 8a3ca5dae6c39f3e99b2cf5e6ca09f4a4b15c43d Mon Sep 17 00:00:00 2001 From: Pedro Nascimento de Lima Date: Fri, 6 Sep 2024 14:48:03 -0400 Subject: [PATCH] updating package docs --- DESCRIPTION | 2 +- R/R6Experiment.R | 2 +- R/R6Sim.package.R | 4 +--- dev/config_attachment.yaml | 12 ++++++++++++ man/R6Experiment_run.Rd | 3 +++ man/{R6Sim.package.Rd => R6Sim-package.Rd} | 8 ++++++-- 6 files changed, 24 insertions(+), 7 deletions(-) create mode 100644 dev/config_attachment.yaml rename man/{R6Sim.package.Rd => R6Sim-package.Rd} (66%) diff --git a/DESCRIPTION b/DESCRIPTION index b123440..3834890 100644 --- a/DESCRIPTION +++ b/DESCRIPTION @@ -32,4 +32,4 @@ VignetteBuilder: Config/testthat/edition: 3 Encoding: UTF-8 LazyData: true -RoxygenNote: 7.2.3 +RoxygenNote: 7.3.1 diff --git a/R/R6Experiment.R b/R/R6Experiment.R index 0676441..265e701 100644 --- a/R/R6Experiment.R +++ b/R/R6Experiment.R @@ -177,7 +177,7 @@ R6Experiment <- R6::R6Class( #' Runs R6Experiment in parallel #' #' - #' This function is most useful to simulate the posterior distribution for a single model in parallel in one machine. This function is not used when calibrating the model and not useful for parallelization across multiple nodes. + #' This function simulates the models included in the experiment, running one simulation for each row in the `policy_design` object. This function supporst local parallel execution, and assumes that each experimental variable in the `policy_design` data.frame is an input that can be set with the `model$set_input()` function. #' #' @param self experiment object #' @param n_cores number of cores to use diff --git a/R/R6Sim.package.R b/R/R6Sim.package.R index 137ee1d..63113a4 100644 --- a/R/R6Sim.package.R +++ b/R/R6Sim.package.R @@ -25,9 +25,7 @@ #' This package implements the \code{\link{R6Sim}} and the \code{\link{R6Experiment}} R6 classes, providing an encapsulated object-oriented framework for simulation modeling studies. #' #' -#' @docType package -#' @name R6Sim.package -NULL +"_PACKAGE" diff --git a/dev/config_attachment.yaml b/dev/config_attachment.yaml new file mode 100644 index 0000000..46e24ec --- /dev/null +++ b/dev/config_attachment.yaml @@ -0,0 +1,12 @@ +path.n: NAMESPACE +path.d: DESCRIPTION +dir.r: R +dir.v: vignettes +dir.t: tests +extra.suggests: ~ +pkg_ignore: ~ +document: yes +normalize: yes +inside_rmd: no +must.exist: yes +check_if_suggests_is_installed: yes diff --git a/man/R6Experiment_run.Rd b/man/R6Experiment_run.Rd index c5fd900..76eb004 100644 --- a/man/R6Experiment_run.Rd +++ b/man/R6Experiment_run.Rd @@ -10,6 +10,7 @@ R6Experiment_run( parallel, cluster_eval_script, model_from_cluster_eval, + cluster_type = "PSOCK", ... ) } @@ -24,6 +25,8 @@ R6Experiment_run( \item{model_from_cluster_eval}{T if model is instantiated in the cluter eval scripts, F otherwise. Use T if using models that need compilation (like odin) and F otherwise.} +\item{cluster_type}{either "FORK" or "PSOCK".} + \item{...}{additional parameters to be passed to the model simulation function.} } \value{ diff --git a/man/R6Sim.package.Rd b/man/R6Sim-package.Rd similarity index 66% rename from man/R6Sim.package.Rd rename to man/R6Sim-package.Rd index b00640b..202bff7 100644 --- a/man/R6Sim.package.Rd +++ b/man/R6Sim-package.Rd @@ -1,9 +1,13 @@ % Generated by roxygen2: do not edit by hand % Please edit documentation in R/R6Sim.package.R \docType{package} -\name{R6Sim.package} -\alias{R6Sim.package} +\name{R6Sim-package} +\alias{R6Sim-package} \title{R6Sim: R6-based Simulation Modeling Toolkit} \description{ This package implements the \code{\link{R6Sim}} and the \code{\link{R6Experiment}} R6 classes, providing an encapsulated object-oriented framework for simulation modeling studies. } +\author{ +\strong{Maintainer}: Pedro Nascimento de Lima \email{plima@rand.org} (\href{https://orcid.org/0000-0001-9057-198X}{ORCID}) + +}