Title: | Execute Pharmacometric Models Using 'shiny' |
Version: | 3.0.2 |
Description: | Execute Nonlinear Mixed Effects (NLME) models for pharmacometrics using a 'shiny' interface. Specify engine parameters and select from different run options, including simple estimation, stepwise covariate search, bootstrapping, simulation, visual predictive check, and more. Models are executed using the 'Certara.RsNLME' package. |
Depends: | R (≥ 4.0) |
License: | LGPL-3 |
URL: | https://certara.github.io/R-RsNLME-model-executor/ |
Encoding: | UTF-8 |
RoxygenNote: | 7.3.2 |
Suggests: | knitr, rmarkdown, testthat (≥ 3.0.0) |
Imports: | Certara.RsNLME, Certara.NLME8, shinyAce, shinymeta, bslib (≥ 0.7.0), htmltools, magrittr, dplyr, shiny (≥ 1.7.4), shinyFiles, shinyjs, shinyWidgets, stringr, tools, fs, ggplot2, future, promises, reshape, jsonlite, DT |
Config/testthat/edition: | 3 |
NeedsCompilation: | no |
Packaged: | 2025-03-19 14:17:26 UTC; jcraig |
Author: | James Craig [aut, cre], Mike Talley [aut], Vitalii Nazarov [aut], Certara USA, Inc [cph, fnd] |
Maintainer: | James Craig <james.craig@certara.com> |
Repository: | CRAN |
Date/Publication: | 2025-03-19 14:50:01 UTC |
Run Model Executor from Pirana
Description
Used by Pirana internally to launch the Model Executor Shiny GUI.
Usage
execute_mmdlModel(metamodelFile, hostsfile)
Arguments
metamodelFile |
Path to existing metamodel file |
hostsfile |
Path to hosts definitions file |
Value
Deploys a Shiny app to execute a Certara.RsNLME
model. Returns NULL
if assigned to an object.
Examples
if (interactive()) {
# Get existing mmdl file
mmdl_file <- system.file("vignettesdata/OneCpt_IVInfusion.mmdl",
package = "Certara.RsNLME")
# Create hosts file json. Note, hosts file is automatically created by Pirana.
hosts_file <- tempfile(pattern = "hosts", fileext = ".json")
jsonlite::write_json(
list(
list(profile_name = "examplehost", cores_number = 1, os = "Windows", parallel_mode="None")),
auto_unbox = TRUE,
path = hosts_file
)
execute_mmdlModel(
mmdl_file,
hosts_file
)
}
Run Model Executor
Description
Used to execute a model developed in Certara.RsNLME
from a Shiny GUI.
Usage
modelExecutorUI(
model,
hosts,
wd,
outputfile = "shiny_dirs.txt",
metamodelFileName = "temp.mmdl",
fromPirana = FALSE
)
Arguments
model |
Model object generated from |
hosts |
One or more hosts generated from |
wd |
Working directory where the model output folders will be created.
If missing, the directory specified in the model object will be used |
outputfile |
Text file providing a list of model output subfolders generated inside |
metamodelFileName |
Name of the resulting metamodel to generate. Only applicable for Pirana. |
fromPirana |
Logical; set to |
Value
Deploys a Shiny app to execute a Certara.RsNLME
model. Returns NULL
if assigned to an object.
Examples
if (interactive()) {
model <- Certara.RsNLME::pkmodel(
parameterization = "Clearance",
absorption = "Intravenous",
numCompartments = 2,
data = Certara.RsNLME::pkData,
ID = "Subject",
A1 = "Amount",
Time = "Act_Time",
CObs = "Conc",
modelName = "pk_model")
modelExecutorUI(model)
}