| Title: | Population Fisher Information Matrix |
|---|---|
| Description: | Evaluate or optimize designs for nonlinear mixed effects models using the Fisher Information matrix; see <doi:10.1093/biomet/84.2.429> and <doi:10.1016/S0169-2607(00)00117-6>. Supports population, individual, and Bayesian 'FIMs', covariates, inter-occasion variability, and D-optimal search ('Fedorov-Wynn', multiplicative, simplex, 'PSO', 'PGBO'). |
| Authors: | Romain Leroux [aut] (ORCID: <https://orcid.org/0009-0009-5779-5303>), France Mentré [cre] (ORCID: <https://orcid.org/0000-0002-7045-1275>), Lucie Fayette [ctb] (ORCID: <https://orcid.org/0009-0001-0048-5998>), Antoine Croxo [ctb] (ORCID: <https://orcid.org/0009-0007-4726-5259>), Jérémy Seurat [ctb] (ORCID: <https://orcid.org/0000-0002-8127-7751>) |
| Maintainer: | France Mentré <[email protected]> |
| License: | GPL-3 |
| Version: | 8.0.1 |
| Built: | 2026-10-16 12:49:26 UTC |
| Source: | https://github.com/cran/PFIM |
Nonlinear mixed-effects models (NLMEM) are widely used in model-based drug development. The population Fisher information matrix (FIM) is an efficient alternative to clinical trial simulation for optimizing study designs. **PFIM 8.0.1** is an R package using the **S7** object system to evaluate and optimize population designs from the FIM.
PFIM includes libraries of PK and PD models (S7 classes): bolus, infusion,
first-order absorption, one- and two-compartment structures, linear or
Michaelis-Menten elimination, direct and turnover PD models, and combined
PK/PD models. Users may also supply custom analytical or ODE models; set
modelClass explicitly or use pfim_resolve_model_class.
The FIM is computed by first-order linearization with a block-diagonal
structure. Population, individual and Bayesian FIMs are available; the
Bayesian FIM provides shrinkage predictions. Covariate effects can be tested
with covariateTest.
Design optimization under the D-criterion uses the simplex algorithm
(Nelder-Mead), the multiplicative algorithm, Fedorov-Wynn, PSO
(Particle Swarm Optimization) and PGBO (Population Genetics Based Optimizer).
Constructors: Evaluation, Optimization,
Arm, Design, ModelParameter,
residual-error and distribution classes, FIM types, and algorithm classes.
Verbs: run, Report, defineFim,
definePKModel, definePKPDModel,
getSE/getRSE/getFisherMatrix/getDcriterion/getShrinkage,
plotEvaluation/plotSE/plotRSE/plotSensitivityIndices/plotWeights/plotFrequencies,
showFIM, covariateTest.
Session: pfim_get_option, pfim_set_option,
pfim_reset_session.
Pipeline helpers (evaluateDesign, optimizeDesign, ...) are
internal.
Package source, issues, and vignettes are available at http://www.pfim.biostat.fr/.
pfim_set_option / pfim_get_option;
pfim_reset_session clears caches.
See ?pfim_set_option for fim.cache, constraints.maxTasks,
and performance options.
Categorical covariates and inter-occasion variability (IOV) are supported
for population, individual and Bayesian FIMs; covariate effect tests use
the population FIM. The number of occasions is inferred automatically from
the model. Results are shown via show(), plots (ggplot2), and
HTML reports.
Author of PFIM 8.0.1: Romain Leroux [email protected] (ORCID).
Contributors: Jérémy Seurat [email protected], Antoine Croxo [email protected], Lucie Fayette [email protected].
Maintainer: France Mentré [email protected] (ORCID).
Dumont C, Lestini G, Le Nagard H, Comets E, Nguyen TT, et al. PFIM 4.0, an extended R program for design evaluation and optimization in nonlinear mixed-effect models. Comput Methods Programs Biomed. 2018;156:217-29.
Chambers JM. Object-Oriented Programming, Functional Programming and R. Stat Sci. 2014;29:167-80.
Nelder JA, Mead R. A simplex method for function minimization. Comput J. 1965;7:308-13.
Seurat J, Tang Y, Mentré F, Nguyen TT. Finding optimal design in nonlinear mixed effect models using multiplicative algorithms. Comput Methods Programs Biomed. 2021;207:106126.
Fedorov VV. Theory of Optimal Experiments. Academic Press, New York, 1972.
Eberhart RC, Kennedy J. A new optimizer using particle swarm theory. Proc. of the Sixth International Symposium on Micro Machine and Human Science, Nagoya, 4-6 October 1995, 39-43.
Le Nagard H, Chao L, Tenaillon O. The emergence of complexity and restricted pleiotropy in adapting networks. BMC Evol Biol. 2011;11:326.
Wickham H. ggplot2: Elegant Graphics for Data Analysis, Springer-Verlag New York, 2016.
Useful links:
Report bugs at https://github.com/iame-researchCenter/PFIM/issues
Additive covariate link: theta(cov) = mu * (1 + beta * cov).
Additive(beta = 0, combinedEffect = 0, value = 0)Additive(beta = 0, combinedEffect = 0, value = 0)
beta |
Fixed-effect coefficient (default 0). |
combinedEffect |
Combined covariate effect term (default 0). |
value |
Computed adjusted value (default 0). |
An S7 object of class Additive.
Additive(beta = 1, combinedEffect = 0.2)Additive(beta = 1, combinedEffect = 0.2)
Dosing regimen for one outcome: dose amounts, times, infusion duration, and
optional inter-dose interval (tau) for repeated dosing or steady state.
When timeDose has length 1 and dose is longer, solvers treat that
as a shared administration time (see .alignAdministrationDosing).
Administration( outcome = character(0), timeDose = numeric(0), dose = numeric(0), Tinf = numeric(0), tau = 0 )Administration( outcome = character(0), timeDose = numeric(0), dose = numeric(0), Tinf = numeric(0), tau = 0 )
outcome |
Character string: model output receiving the dose.
Library models typically use the catalogue name (typically |
timeDose |
Numeric vector: administration times. |
dose |
Numeric vector: dose amounts (same length as |
Tinf |
Numeric vector: infusion duration (0 or omitted for bolus). |
tau |
Numeric: dosing interval for repeated doses or steady-state models. |
An S7 object of class Administration.
Administration(outcome = "RespPK", timeDose = 0, dose = 100)Administration(outcome = "RespPK", timeDose = 0, dose = 100)
Allowed dose values per outcome when optimizing or reporting designs.
Used by generateDosesCombination() to build the discrete dose grid for
Fedorov-Wynn / multiplicative algorithms (and constraint reports).
AdministrationConstraints(outcome = character(0), doses = list())AdministrationConstraints(outcome = character(0), doses = list())
outcome |
Character string: outcome name. |
doses |
List of admissible dose levels for that outcome. |
An S7 object of class AdministrationConstraints.
source(system.file("examples", "evaluation-minimal.R", package = "PFIM")) # help(AdministrationConstraints)source(system.file("examples", "evaluation-minimal.R", package = "PFIM")) # help(AdministrationConstraints)
One experimental arm: subjects, dosing, sampling times, and slots filled during design evaluation (model predictions, gradients, variance, FIM).
Arm( name = character(0), size = numeric(0), administrations = list(), initialConditions = list(), initialCondition = NULL, samplingTimes = list(), administrationsConstraints = list(), samplingTimesConstraints = list(), evaluationModel = list(), evaluationGradients = list(), evaluationVariance = list(), evaluationFim = NULL )Arm( name = character(0), size = numeric(0), administrations = list(), initialConditions = list(), initialCondition = NULL, samplingTimes = list(), administrationsConstraints = list(), samplingTimesConstraints = list(), evaluationModel = list(), evaluationGradients = list(), evaluationVariance = list(), evaluationFim = NULL )
name |
Character string: arm identifier. |
size |
Numeric: number of subjects in the arm. |
administrations |
List of |
initialConditions |
List of ODE initial conditions (name = state).
Values may be numeric or a character expression in typical values and
|
initialCondition |
Alias of |
samplingTimes |
List of |
administrationsConstraints |
List of |
samplingTimesConstraints |
List of |
evaluationModel |
Model predictions at sampling times (filled by |
evaluationGradients |
Gradients of responses w.r.t. parameters (nested if covariates/IOV). |
evaluationVariance |
Residual variance structure for the arm. |
evaluationFim |
FIM object after |
An S7 object of class Arm.
source(system.file("examples", "evaluation-minimal.R", package = "PFIM")) arm = prop(prop(ev, "designs")[[1L]], "arms")[[1L]] length(prop(prop(arm, "samplingTimes")[[1L]], "samplings"))source(system.file("examples", "evaluation-minimal.R", package = "PFIM")) arm = prop(prop(ev, "designs")[[1L]], "arms")[[1L]] length(prop(prop(arm, "samplingTimes")[[1L]], "samplings"))
Bayesian Fisher information matrix with shrinkage on random effects.
First-order linearization on the random-effect scale. Covariate beta is not a
subject parameter (MAP conditions on ) and is omitted. Across
strata / arms, subject FIMs keep their prior and are aggregated by averaging
covariances: , .
A positive weight on a non-identifiable protocol yields Inf SE for the
null-space parameters. This covariance mixture is not comparable to summing
Fisher matrices (PFIM 6 / PopED on this case).
With IOV (), each occasion uses the marginal FO residual
on the -scale
(equivalent to the block of the augmented system).
BayesianFim( fisherMatrix = numeric(0), fixedEffects = numeric(0), varianceEffects = numeric(0), SEAndRSE = list(), condNumberFixedEffects = 0, condNumberVarianceEffects = 0, shrinkage = numeric(0), singularFim = FALSE )BayesianFim( fisherMatrix = numeric(0), fixedEffects = numeric(0), varianceEffects = numeric(0), SEAndRSE = list(), condNumberFixedEffects = 0, condNumberVarianceEffects = 0, shrinkage = numeric(0), singularFim = FALSE )
fisherMatrix |
Labelled FIM matrix. |
fixedEffects |
Fixed-effects sub-block. |
varianceEffects |
Variance-effects sub-block. |
SEAndRSE |
List with |
condNumberFixedEffects |
Condition number of the fixed-effects block. |
condNumberVarianceEffects |
Condition number of the variance-effects block. |
shrinkage |
Named shrinkage (percent) per parameter (Bayesian FIM). |
singularFim |
|
A BayesianFim object (filled by run()).
vignette("Vignette_01_discrete_design")vignette("Vignette_01_discrete_design")
The class CategoricalCovariate represents a fixed categorical
covariate (constant across occasions): binary or multi-level group
membership (sex, genotype, centre, ...).
The constructor validates that categoriesProportions sums to 1
(within floating-point tolerance) before creating the object.
CategoricalCovariate(name, categories, categoriesProportions, effects = list())CategoricalCovariate(name, categories, categoriesProportions, effects = list())
name |
Covariate identifier string. |
categories |
Character vector of category labels. The first element is the reference level. |
categoriesProportions |
Numeric vector of proportions; must sum to 1. |
effects |
Named list of covariate effects per category. |
An S7 object of class CategoricalCovariate.
CategoricalCovariate( name = "Sex", categories = c("M", "F"), categoriesProportions = c(0.5, 0.5) )CategoricalCovariate( name = "Sex", categories = c("M", "F"), categoriesProportions = c(0.5, 0.5) )
The class CategoricalCovariateWithIOV represents a categorical
covariate that varies across occasions (inter-occasion variability design).
Typical use: crossover treatment sequences (AB/BA), period effects, etc.
Each element of sequences is a character vector of category labels,
one per occasion. sequencesProportions gives the fraction of subjects
following each sequence and must sum to 1.
CategoricalCovariateWithIOV( name, categories, sequences, sequencesProportions, effects = list() )CategoricalCovariateWithIOV( name, categories, sequences, sequencesProportions, effects = list() )
name |
Character: covariate identifier. |
categories |
Character vector of category labels; first element is the reference level. |
sequences |
Named list of character vectors (one per sequence
group); names are auto-generated as
|
sequencesProportions |
Numeric vector summing to 1. |
effects |
Named list of covariate effects per category. |
An S7 object of class CategoricalCovariateWithIOV.
CategoricalCovariateWithIOV( name = "Trt", categories = c("A", "B"), sequences = list(c("A", "B"), c("B", "A")), sequencesProportions = c(0.5, 0.5) )CategoricalCovariateWithIOV( name = "Trt", categories = c("A", "B"), sequences = list(c("A", "B"), c("B", "A")), sequencesProportions = c(0.5, 0.5) )
Combined residual error (additive + proportional SD):
variance (sigmaInter + sigmaSlope * f^{cError})^2.
Combined1( output = character(0), sigmaInter = 0, sigmaSlope = 0, sigmaInterFixed = FALSE, sigmaSlopeFixed = FALSE, cError = 1, ... )Combined1( output = character(0), sigmaInter = 0, sigmaSlope = 0, sigmaInterFixed = FALSE, sigmaSlopeFixed = FALSE, cError = 1, ... )
output |
Outcome name. |
sigmaInter |
Additive residual SD. |
sigmaSlope |
Proportional residual SD. |
sigmaInterFixed |
If |
sigmaSlopeFixed |
If |
cError |
Power on the proportional prediction term. |
... |
Legacy |
An S7 object of class Combined1.
Combined1(output = "RespPK", sigmaInter = 0.5, sigmaSlope = 0.1)Combined1(output = "RespPK", sigmaInter = 0.5, sigmaSlope = 0.1)
Combined residual error with independent additive and proportional SDs:
variance sigmaInter^2 + (sigmaSlope * f^{cError})^2.
Matches PopED y*(1+e_prop)+e_add when both sigmas are residual SDs.
Combined2( output = character(0), sigmaInter = 0, sigmaSlope = 0, sigmaInterFixed = FALSE, sigmaSlopeFixed = FALSE, cError = 1, ... )Combined2( output = character(0), sigmaInter = 0, sigmaSlope = 0, sigmaInterFixed = FALSE, sigmaSlopeFixed = FALSE, cError = 1, ... )
output |
Outcome name. |
sigmaInter |
Additive residual SD. |
sigmaSlope |
Proportional residual SD. |
sigmaInterFixed |
If |
sigmaSlopeFixed |
If |
cError |
Power on the proportional prediction term. |
... |
Legacy |
An S7 object of class Combined2.
Combined2(output = "RespPK", sigmaInter = 0.5, sigmaSlope = 0.1)Combined2(output = "RespPK", sigmaInter = 0.5, sigmaSlope = 0.1)
Pure additive residual error: V = sigmaInter^2
(combined1 with sigmaSlope locked to 0).
Constant( output = character(0), sigmaInter = 0, sigmaSlope = 0, sigmaInterFixed = FALSE, sigmaSlopeFixed = FALSE, cError = 1, ... )Constant( output = character(0), sigmaInter = 0, sigmaSlope = 0, sigmaInterFixed = FALSE, sigmaSlopeFixed = FALSE, cError = 1, ... )
output |
Outcome name. |
sigmaInter |
Additive residual SD. |
sigmaSlope |
Proportional residual SD. |
sigmaInterFixed |
If |
sigmaSlopeFixed |
If |
cError |
Power on the proportional prediction term. |
... |
Legacy |
An S7 object of class Constant.
Constant(output = "RespPK", sigmaInter = 0.1)Constant(output = "RespPK", sigmaInter = 0.1)
The class Covariate is the base class for all covariate types.
The constructor doubles as a smart factory: when categories is
supplied it dispatches to the correct concrete subclass:
sequences + sequencesProportions -> CategoricalCovariateWithIOV
categoriesProportions -> CategoricalCovariate
otherwise -> plain Covariate
Covariate( name, effects = list(), categories = NULL, categoriesProportions = NULL, sequences = NULL, sequencesProportions = NULL )Covariate( name, effects = list(), categories = NULL, categoriesProportions = NULL, sequences = NULL, sequencesProportions = NULL )
name |
Character: covariate identifier. |
effects |
Named list of covariate effects per category.
A declared value of 0 still creates a |
categories |
(Optional) Character vector of category labels. |
categoriesProportions |
(Optional) Numeric vector summing to 1. |
sequences |
(Optional) List of category sequences (IOV). |
sequencesProportions |
(Optional) Numeric vector summing to 1. |
An S7 object of class Covariate.
Covariate(name = "Sex", categories = c("M", "F"), categoriesProportions = c(0.5, 0.5), effects = list(F = c(V = log(1.2))))Covariate(name = "Sex", categories = c("M", "F"), categoriesProportions = c(0.5, 0.5), effects = list(F = c(V = log(1.2))))
The class CovariateModelEquation is the base class for the two
covariate structural equations supported by PFIM:
Additive and Exponential.
A covariate model equation adjusts the population mean for individual i with covariate value
Additive:
Exponential:
Concrete subclasses implement computeCovariateValue().
CovariateModelEquation(beta = 0, combinedEffect = 0, value = 0)CovariateModelEquation(beta = 0, combinedEffect = 0, value = 0)
beta |
Fixed-effect coefficient (default 0). |
combinedEffect |
Combined covariate effect term (default 0). |
value |
Computed adjusted value (default 0). |
An S7 object of class CovariateModelEquation.
CovariateModelEquation(beta = 1, combinedEffect = 0.2)CovariateModelEquation(beta = 1, combinedEffect = 0.2)
CovariateTest stores covariate-test results.
CovariateTest( covariate = data.frame(), parameter = data.frame(), nonRelevance = data.frame(), relevance = data.frame(), settings = list() )CovariateTest( covariate = data.frame(), parameter = data.frame(), nonRelevance = data.frame(), relevance = data.frame(), settings = list() )
covariate |
|
parameter |
Deprecated; kept empty (typical |
nonRelevance |
|
relevance |
|
settings |
List of run/display options. |
Significance on covariate effects
TOST non-relevance on
Clinical relevance on
Run options (tests, thetaL/U, targetPower, alpha, N0)
An S7 object of class CovariateTest.
source(system.file("examples", "covariate-test-minimal.R", package = "PFIM")) class(ct)source(system.file("examples", "covariate-test-minimal.R", package = "PFIM")) class(ct)
Experimental design: one or more arms, each with dosing and sampling schedules.
Filled by evaluateDesign() with per-arm FIM results.
Design( name = character(0), size = 0, arms = list(), evaluationArms = list(), numberOfArms = 0, fim = NULL )Design( name = character(0), size = 0, arms = list(), evaluationArms = list(), numberOfArms = 0, fim = NULL )
name |
Character string: design name. |
size |
Total number of subjects (sum of arm sizes). |
arms |
List of |
evaluationArms |
Evaluated arms after |
numberOfArms |
Optional total study size for discrete designs (historical
CRAN field; Mult/FW prefer |
fim |
Aggregated |
An S7 object of class Design.
source(system.file("examples", "evaluation-minimal.R", package = "PFIM")) design = prop(ev, "designs")[[1L]] prop(prop(design, "arms")[[1L]], "size")source(system.file("examples", "evaluation-minimal.R", package = "PFIM")) design = prop(ev, "designs")[[1L]] prop(prop(design, "arms")[[1L]], "size")
Base class for parameter distributions (Normal, LogNormal).
Distribution(name = character(0), mu = 0, omega = 0)Distribution(name = character(0), mu = 0, omega = 0)
name |
Character string: distribution label. |
mu |
Typical value on the natural (untransformed) scale. For
|
omega |
Standard deviation of random effects (IIV). |
An S7 object of class Distribution.
source(system.file("examples", "evaluation-minimal.R", package = "PFIM")) # help(Distribution)source(system.file("examples", "evaluation-minimal.R", package = "PFIM")) # help(Distribution)
Design evaluation: build the model, compute the Fisher information matrix (FIM),
and store results per design. Inherits PFIMProject fields directly.
Use prop for project fields on both Evaluation and
Optimization. After run(), getEvaluationDesign returns
per-design results when several designs were evaluated.
Equation strings may use declared ModelParameter names,
t, dose_* / Tinf_* for administered outcomes, and other
outcome names. Free symbols resolve in knitr::knit_global() (while
knitting) or globalenv(). Names that already exist on the search path
(beta, gamma, pi) are not reported as missing; declare
every model parameter explicitly.
Evaluation( evaluationDesign = list(), name = character(0), modelClass = character(0), modelParameters = list(), modelCovariates = list(), modelCovariatesEquation = character(0), modelEquations = list(), modelFromLibrary = list(), modelError = list(), designs = list(), outputs = list(), fimType = character(0), odeSolverParameters = list(), numberOfOccasions = NA_real_, fim = NULL )Evaluation( evaluationDesign = list(), name = character(0), modelClass = character(0), modelParameters = list(), modelCovariates = list(), modelCovariatesEquation = character(0), modelEquations = list(), modelFromLibrary = list(), modelError = list(), designs = list(), outputs = list(), fimType = character(0), odeSolverParameters = list(), numberOfOccasions = NA_real_, fim = NULL )
evaluationDesign |
List of evaluated designs (filled by |
name |
Character string: project name. |
modelClass |
Model S7 class name; filled by |
modelParameters |
List of |
modelCovariates |
List of covariate objects (from |
modelCovariatesEquation |
See |
modelEquations |
List of model equations (or empty if using the model library). |
modelFromLibrary |
List selecting a built-in PK/PD model. |
modelError |
List of residual error model objects. |
designs |
List of |
outputs |
Named list mapping internal to user output names. |
fimType |
Character: |
odeSolverParameters |
List with |
numberOfOccasions |
Integer number of study occasions; |
fim |
|
An Evaluation object with evaluationDesign and fim filled.
source(system.file("examples", "evaluation-minimal.R", package = "PFIM"))source(system.file("examples", "evaluation-minimal.R", package = "PFIM"))
Exponential covariate link: theta(cov) = mu * exp(beta * cov).
Exponential(beta = 0, combinedEffect = 0, value = 0)Exponential(beta = 0, combinedEffect = 0, value = 0)
beta |
Fixed-effect coefficient (default 0). |
combinedEffect |
Combined covariate effect term (default 0). |
value |
Computed adjusted value (default 0). |
An S7 object of class Exponential.
Exponential(beta = 1, combinedEffect = 0.2)Exponential(beta = 1, combinedEffect = 0.2)
Fedorov-Wynn exchange algorithm for D-optimal sampling-time design (Rcpp kernel).
Pass elementaryProtocols, numberOfSubjects, and
proportionsOfSubjects via optimizerParameters on Optimization.
Optional delta (default 1e-4) is the relative optimality
gap , same role as in the multiplicative algorithm.
Each elementary protocol may be a flat numeric vector (full grid row) or a list of
per-outcome vectors that concatenate to that row (typical PK/PD). A vignette-style
list(pk, pd) with a single proportion is accepted as one multi-outcome protocol.
FedorovWynnAlgorithm(FedorovWynnAlgorithmOutputs = list())FedorovWynnAlgorithm(FedorovWynnAlgorithmOutputs = list())
FedorovWynnAlgorithmOutputs |
Output list from the Rcpp routine. |
FedorovWynnAlgorithm: S7 class
A FedorovWynnAlgorithm specification object for run(Optimization).
vignette("Vignette_01_discrete_design")vignette("Vignette_01_discrete_design")
Base class for Fisher information matrices (PopulationFim,
IndividualFim, BayesianFim).
Fim( fisherMatrix = numeric(0), fixedEffects = numeric(0), varianceEffects = numeric(0), SEAndRSE = list(), condNumberFixedEffects = 0, condNumberVarianceEffects = 0, shrinkage = numeric(0), singularFim = FALSE )Fim( fisherMatrix = numeric(0), fixedEffects = numeric(0), varianceEffects = numeric(0), SEAndRSE = list(), condNumberFixedEffects = 0, condNumberVarianceEffects = 0, shrinkage = numeric(0), singularFim = FALSE )
fisherMatrix |
Labelled FIM matrix. |
fixedEffects |
Fixed-effects sub-block. |
varianceEffects |
Variance-effects sub-block. |
SEAndRSE |
List with |
condNumberFixedEffects |
Condition number of the fixed-effects block. |
condNumberVarianceEffects |
Condition number of the variance-effects block. |
shrinkage |
Named shrinkage (percent) per parameter (Bayesian FIM). |
singularFim |
|
An S7 object holding FIM matrices, SE/RSE tables, and condition numbers.
PopulationFim()PopulationFim()
Retrieve correlation matrix from results
Parameter correlations from the optimal design FIM.
Parameter correlations from the evaluated design FIM.
getCorrelationMatrix(pfimproject, ...)getCorrelationMatrix(pfimproject, ...)
pfimproject |
A |
... |
Optional method arguments. |
Correlation matrix of the parameter estimates.
source(system.file("examples", "evaluation-minimal.R", package = "PFIM")) # help(getCorrelationMatrix)source(system.file("examples", "evaluation-minimal.R", package = "PFIM")) # help(getCorrelationMatrix)
Build HTML tables from a covariate test result
getCovariateTestTables(covariateTestResult, tests = NULL)getCovariateTestTables(covariateTestResult, tests = NULL)
covariateTestResult |
A |
tests |
Optional character vector overriding |
Named list of knitr_kable objects (or NULL if empty).
Element significance is the covariate slot (report alias).
source(system.file("examples", "evaluation-minimal.R", package = "PFIM")) # help(getCovariateTestTables)source(system.file("examples", "evaluation-minimal.R", package = "PFIM")) # help(getCovariateTestTables)
Retrieve D-criterion from project results
D-criterion of the optimal design.
D-criterion of the evaluated design.
getDcriterion(pfimproject, ...)getDcriterion(pfimproject, ...)
pfimproject |
A |
... |
Optional method arguments. |
Numeric D-optimality criterion value.
source(system.file("examples", "evaluation-minimal.R", package = "PFIM")) getDcriterion(ev)source(system.file("examples", "evaluation-minimal.R", package = "PFIM")) getDcriterion(ev)
Retrieve determinant of the Fisher matrix
Determinant of the optimal design FIM.
Determinant of the evaluated design FIM.
getDeterminant(pfimproject, ...)getDeterminant(pfimproject, ...)
pfimproject |
A |
... |
Optional method arguments. |
Numeric determinant of the Fisher information matrix.
source(system.file("examples", "evaluation-minimal.R", package = "PFIM")) getDeterminant(ev)source(system.file("examples", "evaluation-minimal.R", package = "PFIM")) getDeterminant(ev)
run().Per-design evaluation result from a multi-design run().
getEvaluationDesign(evaluation, design = 1L)getEvaluationDesign(evaluation, design = 1L)
evaluation |
An |
design |
Design index (integer) or name (character). |
One element of evaluationDesign (evaluated design with fim).
source(system.file("examples", "evaluation-minimal.R", package = "PFIM")) # help(getEvaluationDesign)source(system.file("examples", "evaluation-minimal.R", package = "PFIM")) # help(getEvaluationDesign)
Runs setEvaluationFim() so dimnames and SE/RSE match the current model
metadata, then returns the matrix blocks used by report helpers, plus
singularFim.
getFisherMatrix(pfimproject, ...)getFisherMatrix(pfimproject, ...)
pfimproject |
A |
... |
Optional method arguments. |
A list with fisherMatrix, fixedEffects,
varianceEffects, and singularFim.
List with fisherMatrix, fixedEffects,
varianceEffects, and singularFim.
source(system.file("examples", "evaluation-minimal.R", package = "PFIM")) getFisherMatrix(ev)source(system.file("examples", "evaluation-minimal.R", package = "PFIM")) getFisherMatrix(ev)
Differs from getDcriterion() (implemented protocol) when joint cells
or Hamilton allocation change the realised design. Requires
MultiplicativeAlgorithm results.
getMixtureDcriterion(pfimproject, ...)getMixtureDcriterion(pfimproject, ...)
pfimproject |
An |
... |
Optional method arguments. |
Numeric D-criterion of the continuous mixture.
algo = MultiplicativeAlgorithm( multiplicativeAlgorithmOutputs = list(mixtureDcriterion = 2, realisedDcriterion = 1.5) ) opt = Optimization( name = "mult_d", modelFromLibrary = list(PKModel = "Linear1BolusSingleDose_kV"), modelParameters = list( ModelParameter(name = "k", distribution = LogNormal(mu = 0.25, omega = 0.5)), ModelParameter(name = "V", distribution = LogNormal(mu = 15, omega = 0.3)) ), modelError = list(Combined1(output = "RespPK", sigmaInter = 0.5, sigmaSlope = 0.15)), optimizer = "MultiplicativeAlgorithm", optimizerParameters = list( lambda = 0.99, delta = 1e-3, numberOfIterations = 20L, weightThreshold = 0.01 ), outputs = list("RespPK"), designs = list(Design( name = "d", arms = list(Arm( name = "a", size = 10, administrations = list(Administration(outcome = "RespPK", timeDose = 0, dose = 100)), samplingTimes = list(SamplingTimes(outcome = "RespPK", samplings = c(1, 4))) )) )), fimType = "individual", optimisationAlgorithmOutputs = list( optimizationAlgorithm = algo, mixtureDcriterion = 2, realisedDcriterion = 1.5 ) ) getMixtureDcriterion(opt)algo = MultiplicativeAlgorithm( multiplicativeAlgorithmOutputs = list(mixtureDcriterion = 2, realisedDcriterion = 1.5) ) opt = Optimization( name = "mult_d", modelFromLibrary = list(PKModel = "Linear1BolusSingleDose_kV"), modelParameters = list( ModelParameter(name = "k", distribution = LogNormal(mu = 0.25, omega = 0.5)), ModelParameter(name = "V", distribution = LogNormal(mu = 15, omega = 0.3)) ), modelError = list(Combined1(output = "RespPK", sigmaInter = 0.5, sigmaSlope = 0.15)), optimizer = "MultiplicativeAlgorithm", optimizerParameters = list( lambda = 0.99, delta = 1e-3, numberOfIterations = 20L, weightThreshold = 0.01 ), outputs = list("RespPK"), designs = list(Design( name = "d", arms = list(Arm( name = "a", size = 10, administrations = list(Administration(outcome = "RespPK", timeDose = 0, dose = 100)), samplingTimes = list(SamplingTimes(outcome = "RespPK", samplings = c(1, 4))) )) )), fimType = "individual", optimisationAlgorithmOutputs = list( optimizationAlgorithm = algo, mixtureDcriterion = 2, realisedDcriterion = 1.5 ) ) getMixtureDcriterion(opt)
Parameter table for reports (mu, omega2, gamma2, fix flags, distribution).
getModelParametersData(modelParameter, ...)getModelParametersData(modelParameter, ...)
modelParameter |
A |
... |
Passed to the S7 method. |
A data frame of model parameter values.
source(system.file("examples", "evaluation-minimal.R", package = "PFIM")) # help(getModelParametersData)source(system.file("examples", "evaluation-minimal.R", package = "PFIM")) # help(getModelParametersData)
Matches getDcriterion() on the optimal evaluation. Requires
MultiplicativeAlgorithm results.
getRealisedDcriterion(pfimproject, ...)getRealisedDcriterion(pfimproject, ...)
pfimproject |
An |
... |
Optional method arguments. |
Numeric D-criterion of the implemented protocol.
algo = MultiplicativeAlgorithm( multiplicativeAlgorithmOutputs = list(mixtureDcriterion = 2, realisedDcriterion = 1.5) ) opt = Optimization( name = "mult_d", modelFromLibrary = list(PKModel = "Linear1BolusSingleDose_kV"), modelParameters = list( ModelParameter(name = "k", distribution = LogNormal(mu = 0.25, omega = 0.5)), ModelParameter(name = "V", distribution = LogNormal(mu = 15, omega = 0.3)) ), modelError = list(Combined1(output = "RespPK", sigmaInter = 0.5, sigmaSlope = 0.15)), optimizer = "MultiplicativeAlgorithm", optimizerParameters = list( lambda = 0.99, delta = 1e-3, numberOfIterations = 20L, weightThreshold = 0.01 ), outputs = list("RespPK"), designs = list(Design( name = "d", arms = list(Arm( name = "a", size = 10, administrations = list(Administration(outcome = "RespPK", timeDose = 0, dose = 100)), samplingTimes = list(SamplingTimes(outcome = "RespPK", samplings = c(1, 4))) )) )), fimType = "individual", optimisationAlgorithmOutputs = list( optimizationAlgorithm = algo, mixtureDcriterion = 2, realisedDcriterion = 1.5 ) ) getRealisedDcriterion(opt)algo = MultiplicativeAlgorithm( multiplicativeAlgorithmOutputs = list(mixtureDcriterion = 2, realisedDcriterion = 1.5) ) opt = Optimization( name = "mult_d", modelFromLibrary = list(PKModel = "Linear1BolusSingleDose_kV"), modelParameters = list( ModelParameter(name = "k", distribution = LogNormal(mu = 0.25, omega = 0.5)), ModelParameter(name = "V", distribution = LogNormal(mu = 15, omega = 0.3)) ), modelError = list(Combined1(output = "RespPK", sigmaInter = 0.5, sigmaSlope = 0.15)), optimizer = "MultiplicativeAlgorithm", optimizerParameters = list( lambda = 0.99, delta = 1e-3, numberOfIterations = 20L, weightThreshold = 0.01 ), outputs = list("RespPK"), designs = list(Design( name = "d", arms = list(Arm( name = "a", size = 10, administrations = list(Administration(outcome = "RespPK", timeDose = 0, dose = 100)), samplingTimes = list(SamplingTimes(outcome = "RespPK", samplings = c(1, 4))) )) )), fimType = "individual", optimisationAlgorithmOutputs = list( optimizationAlgorithm = algo, mixtureDcriterion = 2, realisedDcriterion = 1.5 ) ) getRealisedDcriterion(opt)
Retrieve relative standard errors from results
Relative standard errors from the optimal design FIM (after run()).
Relative standard errors (%) from the evaluated design FIM.
getRSE(pfimproject, ...)getRSE(pfimproject, ...)
pfimproject |
A |
... |
Optional method arguments. |
A list or matrix of relative standard errors (percent).
source(system.file("examples", "evaluation-minimal.R", package = "PFIM")) getRSE(ev)source(system.file("examples", "evaluation-minimal.R", package = "PFIM")) getRSE(ev)
Retrieve standard errors from results
Standard errors from the optimal design FIM (after run()).
Standard errors from the evaluated design FIM.
getSE(pfimproject, ...)getSE(pfimproject, ...)
pfimproject |
A |
... |
Optional method arguments. |
A list or matrix of standard errors for the FIM parameters.
source(system.file("examples", "evaluation-minimal.R", package = "PFIM")) getSE(ev)source(system.file("examples", "evaluation-minimal.R", package = "PFIM")) getSE(ev)
Retrieve shrinkage metrics from results
Parameter shrinkage from the Bayesian optimal-design FIM.
Parameter shrinkage from a Bayesian evaluation FIM (empty for other types).
getShrinkage(pfimproject, ...)getShrinkage(pfimproject, ...)
pfimproject |
A |
... |
Optional method arguments. |
Numeric vector or list of Bayesian shrinkage values.
source(system.file("examples", "evaluation-minimal.R", package = "PFIM")) # help(getShrinkage)source(system.file("examples", "evaluation-minimal.R", package = "PFIM")) # help(getShrinkage)
Individual (subject-level) Fisher information matrix.
Across covariate strata (and arms at design level), subject FIMs are combined
by averaging covariances:
, .
A positive weight on a non-identifiable protocol yields Inf SE.
This mixture is not comparable to summing Fisher matrices (PFIM 6 / PopED).
Covariate beta effects are not subject parameters and are omitted.
With IOV, each occasion uses
for the
and residual blocks.
Arm-level matrices are per-subject.
IndividualFim( fisherMatrix = numeric(0), fixedEffects = numeric(0), varianceEffects = numeric(0), SEAndRSE = list(), condNumberFixedEffects = 0, condNumberVarianceEffects = 0, shrinkage = numeric(0), singularFim = FALSE )IndividualFim( fisherMatrix = numeric(0), fixedEffects = numeric(0), varianceEffects = numeric(0), SEAndRSE = list(), condNumberFixedEffects = 0, condNumberVarianceEffects = 0, shrinkage = numeric(0), singularFim = FALSE )
fisherMatrix |
Labelled FIM matrix. |
fixedEffects |
Fixed-effects sub-block. |
varianceEffects |
Variance-effects sub-block. |
SEAndRSE |
List with |
condNumberFixedEffects |
Condition number of the fixed-effects block. |
condNumberVarianceEffects |
Condition number of the variance-effects block. |
shrinkage |
Named shrinkage (percent) per parameter (Bayesian FIM). |
singularFim |
|
Block-diagonal structure for a single stratum:
where and is the residual
variance-effects block (with the same under IOV).
An IndividualFim object (filled by run()).
source(system.file("examples", "evaluation-minimal.R", package = "PFIM"))source(system.file("examples", "evaluation-minimal.R", package = "PFIM"))
Registry of built-in PK and PD model definitions.
Subclasses LibraryOfPKModels and LibraryOfPDModels store named
equation lists; defineModelEquationsFromLibraryOfModel() looks them up
via the package instances pkModelLibrary / pdModelLibrary.
LibraryOfModels(models = list())LibraryOfModels(models = list())
models |
List of PK and PD model metadata objects. |
An S7 object of class LibraryOfModels.
length(prop(pkModelLibrary, "models")) length(prop(pdModelLibrary, "models"))length(prop(pkModelLibrary, "models")) length(prop(pdModelLibrary, "models"))
Built-in pharmacodynamic (PD) model library (Emax, turnover, etc.).
Entries are named lists of equation strings (RespPD for immediate
response, Deriv_E for turnover ODEs). Combined with a PK model via
definePKPDModel().
LibraryOfPDModels(models = list())LibraryOfPDModels(models = list())
models |
Named list of built-in PD model equation definitions. |
An S7 object of class LibraryOfPDModels.
names(prop(pdModelLibrary, "models"))[1:5]names(prop(pdModelLibrary, "models"))[1:5]
Built-in pharmacokinetic (PK) model library (bolus, infusion, absorption, one- and two-compartment and Michaelis-Menten structures).
Exported Linear* helpers return equation *strings* (not S7 objects):
two-compartment forms expand hybrid rates (alpha/beta) and partial-fraction
coefficients (A/B) via string substitution. Prefer looking up names in
pkModelLibrary for new code.
LibraryOfPKModels(models = list())LibraryOfPKModels(models = list())
models |
Named list of built-in PK model equation definitions. |
An S7 object of class LibraryOfPKModels.
names(prop(pkModelLibrary, "models"))[1:5] nzchar(Linear2BolusSingleDose_ClQV1V2())names(prop(pkModelLibrary, "models"))[1:5] nzchar(Linear2BolusSingleDose_ClQV1V2())
Two-compartment IV bolus (Cl, Q, V1, V2 parameterization).
Linear2BolusSingleDose_ClQV1V2()Linear2BolusSingleDose_ClQV1V2()
Character string: closed-form PK equation.
nzchar(Linear2BolusSingleDose_ClQV1V2())nzchar(Linear2BolusSingleDose_ClQV1V2())
Analytic PK equation: Linear2BolusSingleDose_kk12k21V (micro-constant form).
Linear2BolusSingleDose_kk12k21V()Linear2BolusSingleDose_kk12k21V()
Character string: closed-form PK equation.
nzchar(Linear2BolusSingleDose_kk12k21V())nzchar(Linear2BolusSingleDose_kk12k21V())
Analytic PK equation: Linear2BolusSteadyState_ClQV1V2tau.
Linear2BolusSteadyState_ClQV1V2tau()Linear2BolusSteadyState_ClQV1V2tau()
Character string: closed-form PK equation.
nzchar(Linear2BolusSteadyState_ClQV1V2tau())nzchar(Linear2BolusSteadyState_ClQV1V2tau())
Analytic PK equation: Linear2BolusSteadyState_kk12k21Vtau.
Linear2BolusSteadyState_kk12k21Vtau()Linear2BolusSteadyState_kk12k21Vtau()
Character string: closed-form PK equation.
nzchar(Linear2BolusSteadyState_kk12k21Vtau())nzchar(Linear2BolusSteadyState_kk12k21Vtau())
Analytic PK equation: Linear2FirstOrderSingleDose_kaClQV1V2.
Linear2FirstOrderSingleDose_kaClQV1V2()Linear2FirstOrderSingleDose_kaClQV1V2()
Character string: closed-form PK equation.
nzchar(Linear2FirstOrderSingleDose_kaClQV1V2())nzchar(Linear2FirstOrderSingleDose_kaClQV1V2())
Analytic PK equation: Linear2FirstOrderSingleDose_kakk12k21V.
Linear2FirstOrderSingleDose_kakk12k21V()Linear2FirstOrderSingleDose_kakk12k21V()
Character string: closed-form PK equation.
nzchar(Linear2FirstOrderSingleDose_kakk12k21V())nzchar(Linear2FirstOrderSingleDose_kakk12k21V())
Analytic PK equation: Linear2FirstOrderSteadyState_kaClQV1V2tau.
Linear2FirstOrderSteadyState_kaClQV1V2tau()Linear2FirstOrderSteadyState_kaClQV1V2tau()
Character string: closed-form PK equation.
nzchar(Linear2FirstOrderSteadyState_kaClQV1V2tau())nzchar(Linear2FirstOrderSteadyState_kaClQV1V2tau())
Analytic PK equation: Linear2FirstOrderSteadyState_kakk12k21Vtau.
Linear2FirstOrderSteadyState_kakk12k21Vtau()Linear2FirstOrderSteadyState_kakk12k21Vtau()
Character string: closed-form PK equation.
nzchar(Linear2FirstOrderSteadyState_kakk12k21Vtau())nzchar(Linear2FirstOrderSteadyState_kakk12k21Vtau())
Analytic PK equation: Linear2InfusionSingleDose_ClQV1V2.
Linear2InfusionSingleDose_ClQV1V2()Linear2InfusionSingleDose_ClQV1V2()
Named list with duringInfusion / afterInfusion equation strings.
nzchar(Linear2InfusionSingleDose_ClQV1V2()$duringInfusion$RespPK)nzchar(Linear2InfusionSingleDose_ClQV1V2()$duringInfusion$RespPK)
Analytic PK equation: Linear2InfusionSingleDose_kk12k21V.
Linear2InfusionSingleDose_kk12k21V()Linear2InfusionSingleDose_kk12k21V()
Named list with duringInfusion / afterInfusion equation strings.
nzchar(Linear2InfusionSingleDose_kk12k21V()$duringInfusion$RespPK)nzchar(Linear2InfusionSingleDose_kk12k21V()$duringInfusion$RespPK)
Analytic PK equation: Linear2InfusionSteadyState_ClQV1V2tau.
Linear2InfusionSteadyState_ClQV1V2tau()Linear2InfusionSteadyState_ClQV1V2tau()
Named list with duringInfusion / afterInfusion equation strings.
nzchar(Linear2InfusionSteadyState_ClQV1V2tau()$duringInfusion$RespPK)nzchar(Linear2InfusionSteadyState_ClQV1V2tau()$duringInfusion$RespPK)
Analytic PK equation: Linear2InfusionSteadyState_kk12k21Vtau.
Linear2InfusionSteadyState_kk12k21Vtau()Linear2InfusionSteadyState_kk12k21Vtau()
Named list with duringInfusion / afterInfusion equation strings.
nzchar(Linear2InfusionSteadyState_kk12k21Vtau()$duringInfusion$RespPK)nzchar(Linear2InfusionSteadyState_kk12k21Vtau()$duringInfusion$RespPK)
Log-normal distribution for positive PK/PD parameters (default in PFIM).
LogNormal(name = character(0), mu = 0, omega = 0)LogNormal(name = character(0), mu = 0, omega = 0)
name |
Character string: distribution label. |
mu |
Typical value on the natural (untransformed) scale. For
|
omega |
Standard deviation of random effects (IIV). |
An S7 object of class LogNormal.
LogNormal(mu = 1, omega = 0.3)LogNormal(mu = 1, omega = 0.3)
Internal model object built from a PFIMProject: parameters, covariates,
equations, and evaluation hooks (gradients, variance).
Model( name = character(0), modelParameters = list(), modelCovariatesEquation = NULL, modelCovariates = list(), covariatesEffect = list(), covariatesCombination = list(), modelParametersWithCovariates = list(), numberOfOccasions = 1, omegaWithIOV = numeric(0), samplings = numeric(0), modelEquations = list(), wrapper = NULL, outputFormula = list(), outputNames = character(0), variableNames = character(0), outcomesWithAdministration = character(0), outcomesWithNoAdministration = character(0), modelError = list(), odeSolverParameters = list(), parametersForComputingGradient = list(), initialConditions = numeric(0), functionArguments = character(0), functionArgumentsSymbol = list() )Model( name = character(0), modelParameters = list(), modelCovariatesEquation = NULL, modelCovariates = list(), covariatesEffect = list(), covariatesCombination = list(), modelParametersWithCovariates = list(), numberOfOccasions = 1, omegaWithIOV = numeric(0), samplings = numeric(0), modelEquations = list(), wrapper = NULL, outputFormula = list(), outputNames = character(0), variableNames = character(0), outcomesWithAdministration = character(0), outcomesWithNoAdministration = character(0), modelError = list(), odeSolverParameters = list(), parametersForComputingGradient = list(), initialConditions = numeric(0), functionArguments = character(0), functionArgumentsSymbol = list() )
name |
Model name. |
modelParameters |
List of |
modelCovariatesEquation |
|
modelCovariates |
List of covariate objects. |
covariatesEffect |
Nested covariate effect structure (internal). |
covariatesCombination |
Covariate combination table (internal). |
modelParametersWithCovariates |
Per-combination/occasion parameters (internal). |
numberOfOccasions |
Number of study occasions (set on the |
omegaWithIOV |
IIV/IOV variance vector for population FIM (internal). |
samplings |
Sampling times for the current arm. |
modelEquations |
Model equations (analytic or ODE). |
wrapper |
Compiled or R function wrapper for predictions. |
outputFormula |
Output expressions per outcome (character strings). |
outputNames |
Character vector of outcome names. |
variableNames |
State variable names. |
outcomesWithAdministration |
Outcomes linked to dosing. |
outcomesWithNoAdministration |
Outcomes without dosing. |
modelError |
List of residual error models. |
odeSolverParameters |
|
parametersForComputingGradient |
Internal FD stencil ( |
initialConditions |
ODE initial conditions. |
functionArguments |
Names passed to the model function. |
functionArgumentsSymbol |
Symbolic argument list for parsing. |
An S7 object of class Model.
Model()Model()
Closed-form (non-ODE) PK/PD model with bolus or explicit dosing.
ModelAnalytic( name = character(0), modelParameters = list(), modelCovariatesEquation = NULL, modelCovariates = list(), covariatesEffect = list(), covariatesCombination = list(), modelParametersWithCovariates = list(), numberOfOccasions = 1, omegaWithIOV = numeric(0), samplings = numeric(0), modelEquations = list(), wrapper = NULL, outputFormula = list(), outputNames = character(0), variableNames = character(0), outcomesWithAdministration = character(0), outcomesWithNoAdministration = character(0), modelError = list(), odeSolverParameters = list(), parametersForComputingGradient = list(), initialConditions = numeric(0), functionArguments = character(0), functionArgumentsSymbol = list(), wrapperModelAnalytic = list(), functionArgumentsModelAnalytic = list(), functionArgumentsSymbolModelAnalytic = list(), solverInputs = list() )ModelAnalytic( name = character(0), modelParameters = list(), modelCovariatesEquation = NULL, modelCovariates = list(), covariatesEffect = list(), covariatesCombination = list(), modelParametersWithCovariates = list(), numberOfOccasions = 1, omegaWithIOV = numeric(0), samplings = numeric(0), modelEquations = list(), wrapper = NULL, outputFormula = list(), outputNames = character(0), variableNames = character(0), outcomesWithAdministration = character(0), outcomesWithNoAdministration = character(0), modelError = list(), odeSolverParameters = list(), parametersForComputingGradient = list(), initialConditions = numeric(0), functionArguments = character(0), functionArgumentsSymbol = list(), wrapperModelAnalytic = list(), functionArgumentsModelAnalytic = list(), functionArgumentsSymbolModelAnalytic = list(), solverInputs = list() )
name |
Model name. |
modelParameters |
List of |
modelCovariatesEquation |
|
modelCovariates |
List of covariate objects. |
covariatesEffect |
Nested covariate effect structure (internal). |
covariatesCombination |
Covariate combination table (internal). |
modelParametersWithCovariates |
Per-combination/occasion parameters (internal). |
numberOfOccasions |
Number of study occasions (set on the |
omegaWithIOV |
IIV/IOV variance vector for population FIM (internal). |
samplings |
Sampling times for the current arm. |
modelEquations |
Model equations (analytic or ODE). |
wrapper |
Compiled or R function wrapper for predictions. |
outputFormula |
Output expressions per outcome (character strings). |
outputNames |
Character vector of outcome names. |
variableNames |
State variable names. |
outcomesWithAdministration |
Outcomes linked to dosing. |
outcomesWithNoAdministration |
Outcomes without dosing. |
modelError |
List of residual error models. |
odeSolverParameters |
|
parametersForComputingGradient |
Internal FD stencil ( |
initialConditions |
ODE initial conditions. |
functionArguments |
Names passed to the model function. |
functionArgumentsSymbol |
Symbolic argument list for parsing. |
wrapperModelAnalytic |
Wrapper for the analytic solver. |
functionArgumentsModelAnalytic |
A list with the function arguments of the wrapper. |
functionArgumentsSymbolModelAnalytic |
A list with the function argument symbols. |
solverInputs |
A list with the solver inputs. |
An S7 object of class ModelAnalytic.
ModelAnalytic()ModelAnalytic()
Closed-form model with infusion (dose in equations).
Equations come as duringInfusion / afterInfusion pairs; evaluation
superposes past doses (after formula) with the active infusion (during formula)
using half-open windows .
ModelAnalyticInfusion( name = character(0), modelParameters = list(), modelCovariatesEquation = NULL, modelCovariates = list(), covariatesEffect = list(), covariatesCombination = list(), modelParametersWithCovariates = list(), numberOfOccasions = 1, omegaWithIOV = numeric(0), samplings = numeric(0), modelEquations = list(), wrapper = NULL, outputFormula = list(), outputNames = character(0), variableNames = character(0), outcomesWithAdministration = character(0), outcomesWithNoAdministration = character(0), modelError = list(), odeSolverParameters = list(), parametersForComputingGradient = list(), initialConditions = numeric(0), functionArguments = character(0), functionArgumentsSymbol = list(), wrapperModelAnalyticInfusion = list(), functionArgumentsModelAnalyticInfusion = list(), functionArgumentsSymbolModelAnalyticInfusion = list(), solverInputs = list() )ModelAnalyticInfusion( name = character(0), modelParameters = list(), modelCovariatesEquation = NULL, modelCovariates = list(), covariatesEffect = list(), covariatesCombination = list(), modelParametersWithCovariates = list(), numberOfOccasions = 1, omegaWithIOV = numeric(0), samplings = numeric(0), modelEquations = list(), wrapper = NULL, outputFormula = list(), outputNames = character(0), variableNames = character(0), outcomesWithAdministration = character(0), outcomesWithNoAdministration = character(0), modelError = list(), odeSolverParameters = list(), parametersForComputingGradient = list(), initialConditions = numeric(0), functionArguments = character(0), functionArgumentsSymbol = list(), wrapperModelAnalyticInfusion = list(), functionArgumentsModelAnalyticInfusion = list(), functionArgumentsSymbolModelAnalyticInfusion = list(), solverInputs = list() )
name |
Model name. |
modelParameters |
List of |
modelCovariatesEquation |
|
modelCovariates |
List of covariate objects. |
covariatesEffect |
Nested covariate effect structure (internal). |
covariatesCombination |
Covariate combination table (internal). |
modelParametersWithCovariates |
Per-combination/occasion parameters (internal). |
numberOfOccasions |
Number of study occasions (set on the |
omegaWithIOV |
IIV/IOV variance vector for population FIM (internal). |
samplings |
Sampling times for the current arm. |
modelEquations |
Model equations (analytic or ODE). |
wrapper |
Compiled or R function wrapper for predictions. |
outputFormula |
Output expressions per outcome (character strings). |
outputNames |
Character vector of outcome names. |
variableNames |
State variable names. |
outcomesWithAdministration |
Outcomes linked to dosing. |
outcomesWithNoAdministration |
Outcomes without dosing. |
modelError |
List of residual error models. |
odeSolverParameters |
|
parametersForComputingGradient |
Internal FD stencil ( |
initialConditions |
ODE initial conditions. |
functionArguments |
Names passed to the model function. |
functionArgumentsSymbol |
Symbolic argument list for parsing. |
wrapperModelAnalyticInfusion |
Wrapper for the analytic solver. |
functionArgumentsModelAnalyticInfusion |
A list with the function arguments. |
functionArgumentsSymbolModelAnalyticInfusion |
A list with the function argument symbols. |
solverInputs |
A list with the solver inputs. |
The requested PFIM result.
ModelAnalyticInfusion()ModelAnalyticInfusion()
Analytic infusion model at steady state.
ModelAnalyticInfusionSteadyState( name = character(0), modelParameters = list(), modelCovariatesEquation = NULL, modelCovariates = list(), covariatesEffect = list(), covariatesCombination = list(), modelParametersWithCovariates = list(), numberOfOccasions = 1, omegaWithIOV = numeric(0), samplings = numeric(0), modelEquations = list(), wrapper = NULL, outputFormula = list(), outputNames = character(0), variableNames = character(0), outcomesWithAdministration = character(0), outcomesWithNoAdministration = character(0), modelError = list(), odeSolverParameters = list(), parametersForComputingGradient = list(), initialConditions = numeric(0), functionArguments = character(0), functionArgumentsSymbol = list(), wrapperModelAnalyticInfusion = list(), functionArgumentsModelAnalyticInfusion = list(), functionArgumentsSymbolModelAnalyticInfusion = list(), solverInputs = list() )ModelAnalyticInfusionSteadyState( name = character(0), modelParameters = list(), modelCovariatesEquation = NULL, modelCovariates = list(), covariatesEffect = list(), covariatesCombination = list(), modelParametersWithCovariates = list(), numberOfOccasions = 1, omegaWithIOV = numeric(0), samplings = numeric(0), modelEquations = list(), wrapper = NULL, outputFormula = list(), outputNames = character(0), variableNames = character(0), outcomesWithAdministration = character(0), outcomesWithNoAdministration = character(0), modelError = list(), odeSolverParameters = list(), parametersForComputingGradient = list(), initialConditions = numeric(0), functionArguments = character(0), functionArgumentsSymbol = list(), wrapperModelAnalyticInfusion = list(), functionArgumentsModelAnalyticInfusion = list(), functionArgumentsSymbolModelAnalyticInfusion = list(), solverInputs = list() )
name |
Model name. |
modelParameters |
List of |
modelCovariatesEquation |
|
modelCovariates |
List of covariate objects. |
covariatesEffect |
Nested covariate effect structure (internal). |
covariatesCombination |
Covariate combination table (internal). |
modelParametersWithCovariates |
Per-combination/occasion parameters (internal). |
numberOfOccasions |
Number of study occasions (set on the |
omegaWithIOV |
IIV/IOV variance vector for population FIM (internal). |
samplings |
Sampling times for the current arm. |
modelEquations |
Model equations (analytic or ODE). |
wrapper |
Compiled or R function wrapper for predictions. |
outputFormula |
Output expressions per outcome (character strings). |
outputNames |
Character vector of outcome names. |
variableNames |
State variable names. |
outcomesWithAdministration |
Outcomes linked to dosing. |
outcomesWithNoAdministration |
Outcomes without dosing. |
modelError |
List of residual error models. |
odeSolverParameters |
|
parametersForComputingGradient |
Internal FD stencil ( |
initialConditions |
ODE initial conditions. |
functionArguments |
Names passed to the model function. |
functionArgumentsSymbol |
Symbolic argument list for parsing. |
wrapperModelAnalyticInfusion |
Wrapper for the analytic solver. |
functionArgumentsModelAnalyticInfusion |
A list with the function arguments. |
functionArgumentsSymbolModelAnalyticInfusion |
A list with the function argument symbols. |
solverInputs |
A list with the solver inputs. |
An S7 object of class ModelAnalyticInfusionSteadyState.
ModelAnalyticInfusionSteadyState()ModelAnalyticInfusionSteadyState()
Analytic model at steady state (tau in equations).
ModelAnalyticSteadyState( name = character(0), modelParameters = list(), modelCovariatesEquation = NULL, modelCovariates = list(), covariatesEffect = list(), covariatesCombination = list(), modelParametersWithCovariates = list(), numberOfOccasions = 1, omegaWithIOV = numeric(0), samplings = numeric(0), modelEquations = list(), wrapper = NULL, outputFormula = list(), outputNames = character(0), variableNames = character(0), outcomesWithAdministration = character(0), outcomesWithNoAdministration = character(0), modelError = list(), odeSolverParameters = list(), parametersForComputingGradient = list(), initialConditions = numeric(0), functionArguments = character(0), functionArgumentsSymbol = list(), wrapperModelAnalytic = list(), functionArgumentsModelAnalytic = list(), functionArgumentsSymbolModelAnalytic = list(), solverInputs = list() )ModelAnalyticSteadyState( name = character(0), modelParameters = list(), modelCovariatesEquation = NULL, modelCovariates = list(), covariatesEffect = list(), covariatesCombination = list(), modelParametersWithCovariates = list(), numberOfOccasions = 1, omegaWithIOV = numeric(0), samplings = numeric(0), modelEquations = list(), wrapper = NULL, outputFormula = list(), outputNames = character(0), variableNames = character(0), outcomesWithAdministration = character(0), outcomesWithNoAdministration = character(0), modelError = list(), odeSolverParameters = list(), parametersForComputingGradient = list(), initialConditions = numeric(0), functionArguments = character(0), functionArgumentsSymbol = list(), wrapperModelAnalytic = list(), functionArgumentsModelAnalytic = list(), functionArgumentsSymbolModelAnalytic = list(), solverInputs = list() )
name |
Model name. |
modelParameters |
List of |
modelCovariatesEquation |
|
modelCovariates |
List of covariate objects. |
covariatesEffect |
Nested covariate effect structure (internal). |
covariatesCombination |
Covariate combination table (internal). |
modelParametersWithCovariates |
Per-combination/occasion parameters (internal). |
numberOfOccasions |
Number of study occasions (set on the |
omegaWithIOV |
IIV/IOV variance vector for population FIM (internal). |
samplings |
Sampling times for the current arm. |
modelEquations |
Model equations (analytic or ODE). |
wrapper |
Compiled or R function wrapper for predictions. |
outputFormula |
Output expressions per outcome (character strings). |
outputNames |
Character vector of outcome names. |
variableNames |
State variable names. |
outcomesWithAdministration |
Outcomes linked to dosing. |
outcomesWithNoAdministration |
Outcomes without dosing. |
modelError |
List of residual error models. |
odeSolverParameters |
|
parametersForComputingGradient |
Internal FD stencil ( |
initialConditions |
ODE initial conditions. |
functionArguments |
Names passed to the model function. |
functionArgumentsSymbol |
Symbolic argument list for parsing. |
wrapperModelAnalytic |
Wrapper for the analytic solver. |
functionArgumentsModelAnalytic |
A list with the function arguments. |
functionArgumentsSymbolModelAnalytic |
A list with the function argument symbols. |
solverInputs |
A list with the solver inputs. |
ModelAnalyticSteadyState
An S7 object of class ModelAnalyticSteadyState.
ModelAnalyticSteadyState()ModelAnalyticSteadyState()
Base class for residual error models (Constant, Combined1,
Combined2, Proportional).
Variance is determined by sigmaInter (additive SD),
sigmaSlope (proportional SD), cError, and
varianceForm:
"combined1":
"combined2": (PopED-style)
A sigma is estimable in the FIM iff it is non-zero and not marked fixed
(sigmaInterFixed / sigmaSlopeFixed).
ModelError( output = "output", sigmaInter = 0, sigmaSlope = 0, sigmaInterFixed = FALSE, sigmaSlopeFixed = FALSE, cError = 1, varianceForm = "combined1", ... )ModelError( output = "output", sigmaInter = 0, sigmaSlope = 0, sigmaInterFixed = FALSE, sigmaSlopeFixed = FALSE, cError = 1, varianceForm = "combined1", ... )
output |
Outcome name. |
sigmaInter |
Additive residual SD. |
sigmaSlope |
Proportional residual SD. |
sigmaInterFixed |
If |
sigmaSlopeFixed |
If |
cError |
Power on the proportional prediction term. |
varianceForm |
|
... |
Legacy |
An S7 object of class ModelError.
ModelError()ModelError()
Base class for infusion administration models.
ModelInfusion( name = character(0), modelParameters = list(), modelCovariatesEquation = NULL, modelCovariates = list(), covariatesEffect = list(), covariatesCombination = list(), modelParametersWithCovariates = list(), numberOfOccasions = 1, omegaWithIOV = numeric(0), samplings = numeric(0), modelEquations = list(), wrapper = NULL, outputFormula = list(), outputNames = character(0), variableNames = character(0), outcomesWithAdministration = character(0), outcomesWithNoAdministration = character(0), modelError = list(), odeSolverParameters = list(), parametersForComputingGradient = list(), initialConditions = numeric(0), functionArguments = character(0), functionArgumentsSymbol = list() )ModelInfusion( name = character(0), modelParameters = list(), modelCovariatesEquation = NULL, modelCovariates = list(), covariatesEffect = list(), covariatesCombination = list(), modelParametersWithCovariates = list(), numberOfOccasions = 1, omegaWithIOV = numeric(0), samplings = numeric(0), modelEquations = list(), wrapper = NULL, outputFormula = list(), outputNames = character(0), variableNames = character(0), outcomesWithAdministration = character(0), outcomesWithNoAdministration = character(0), modelError = list(), odeSolverParameters = list(), parametersForComputingGradient = list(), initialConditions = numeric(0), functionArguments = character(0), functionArgumentsSymbol = list() )
name |
Model name. |
modelParameters |
List of |
modelCovariatesEquation |
|
modelCovariates |
List of covariate objects. |
covariatesEffect |
Nested covariate effect structure (internal). |
covariatesCombination |
Covariate combination table (internal). |
modelParametersWithCovariates |
Per-combination/occasion parameters (internal). |
numberOfOccasions |
Number of study occasions (set on the |
omegaWithIOV |
IIV/IOV variance vector for population FIM (internal). |
samplings |
Sampling times for the current arm. |
modelEquations |
Model equations (analytic or ODE). |
wrapper |
Compiled or R function wrapper for predictions. |
outputFormula |
Output expressions per outcome (character strings). |
outputNames |
Character vector of outcome names. |
variableNames |
State variable names. |
outcomesWithAdministration |
Outcomes linked to dosing. |
outcomesWithNoAdministration |
Outcomes without dosing. |
modelError |
List of residual error models. |
odeSolverParameters |
|
parametersForComputingGradient |
Internal FD stencil ( |
initialConditions |
ODE initial conditions. |
functionArguments |
Names passed to the model function. |
functionArgumentsSymbol |
Symbolic argument list for parsing. |
An S7 object of class ModelInfusion.
ModelInfusion()ModelInfusion()
Base class for models integrated with deSolve.
ModelODE( name = character(0), modelParameters = list(), modelCovariatesEquation = NULL, modelCovariates = list(), covariatesEffect = list(), covariatesCombination = list(), modelParametersWithCovariates = list(), numberOfOccasions = 1, omegaWithIOV = numeric(0), samplings = numeric(0), modelEquations = list(), wrapper = NULL, outputFormula = list(), outputNames = character(0), variableNames = character(0), outcomesWithAdministration = character(0), outcomesWithNoAdministration = character(0), modelError = list(), odeSolverParameters = list(), parametersForComputingGradient = list(), initialConditions = numeric(0), functionArguments = character(0), functionArgumentsSymbol = list() )ModelODE( name = character(0), modelParameters = list(), modelCovariatesEquation = NULL, modelCovariates = list(), covariatesEffect = list(), covariatesCombination = list(), modelParametersWithCovariates = list(), numberOfOccasions = 1, omegaWithIOV = numeric(0), samplings = numeric(0), modelEquations = list(), wrapper = NULL, outputFormula = list(), outputNames = character(0), variableNames = character(0), outcomesWithAdministration = character(0), outcomesWithNoAdministration = character(0), modelError = list(), odeSolverParameters = list(), parametersForComputingGradient = list(), initialConditions = numeric(0), functionArguments = character(0), functionArgumentsSymbol = list() )
name |
Model name. |
modelParameters |
List of |
modelCovariatesEquation |
|
modelCovariates |
List of covariate objects. |
covariatesEffect |
Nested covariate effect structure (internal). |
covariatesCombination |
Covariate combination table (internal). |
modelParametersWithCovariates |
Per-combination/occasion parameters (internal). |
numberOfOccasions |
Number of study occasions (set on the |
omegaWithIOV |
IIV/IOV variance vector for population FIM (internal). |
samplings |
Sampling times for the current arm. |
modelEquations |
Model equations (analytic or ODE). |
wrapper |
Compiled or R function wrapper for predictions. |
outputFormula |
Output expressions per outcome (character strings). |
outputNames |
Character vector of outcome names. |
variableNames |
State variable names. |
outcomesWithAdministration |
Outcomes linked to dosing. |
outcomesWithNoAdministration |
Outcomes without dosing. |
modelError |
List of residual error models. |
odeSolverParameters |
|
parametersForComputingGradient |
Internal FD stencil ( |
initialConditions |
ODE initial conditions. |
functionArguments |
Names passed to the model function. |
functionArgumentsSymbol |
Symbolic argument list for parsing. |
An S7 object of class ModelODE.
ModelODE()ModelODE()
ODE bolus model with doses in initial conditions.
ModelODEBolus( name = character(0), modelParameters = list(), modelCovariatesEquation = NULL, modelCovariates = list(), covariatesEffect = list(), covariatesCombination = list(), modelParametersWithCovariates = list(), numberOfOccasions = 1, omegaWithIOV = numeric(0), samplings = numeric(0), modelEquations = list(), wrapper = NULL, outputFormula = list(), outputNames = character(0), variableNames = character(0), outcomesWithAdministration = character(0), outcomesWithNoAdministration = character(0), modelError = list(), odeSolverParameters = list(), parametersForComputingGradient = list(), initialConditions = numeric(0), functionArguments = character(0), functionArgumentsSymbol = list(), modelODE = function() NULL, doseEvent = list(), solverInputs = list() )ModelODEBolus( name = character(0), modelParameters = list(), modelCovariatesEquation = NULL, modelCovariates = list(), covariatesEffect = list(), covariatesCombination = list(), modelParametersWithCovariates = list(), numberOfOccasions = 1, omegaWithIOV = numeric(0), samplings = numeric(0), modelEquations = list(), wrapper = NULL, outputFormula = list(), outputNames = character(0), variableNames = character(0), outcomesWithAdministration = character(0), outcomesWithNoAdministration = character(0), modelError = list(), odeSolverParameters = list(), parametersForComputingGradient = list(), initialConditions = numeric(0), functionArguments = character(0), functionArgumentsSymbol = list(), modelODE = function() NULL, doseEvent = list(), solverInputs = list() )
name |
Model name. |
modelParameters |
List of |
modelCovariatesEquation |
|
modelCovariates |
List of covariate objects. |
covariatesEffect |
Nested covariate effect structure (internal). |
covariatesCombination |
Covariate combination table (internal). |
modelParametersWithCovariates |
Per-combination/occasion parameters (internal). |
numberOfOccasions |
Number of study occasions (set on the |
omegaWithIOV |
IIV/IOV variance vector for population FIM (internal). |
samplings |
Sampling times for the current arm. |
modelEquations |
Model equations (analytic or ODE). |
wrapper |
Compiled or R function wrapper for predictions. |
outputFormula |
Output expressions per outcome (character strings). |
outputNames |
Character vector of outcome names. |
variableNames |
State variable names. |
outcomesWithAdministration |
Outcomes linked to dosing. |
outcomesWithNoAdministration |
Outcomes without dosing. |
modelError |
List of residual error models. |
odeSolverParameters |
|
parametersForComputingGradient |
Internal FD stencil ( |
initialConditions |
ODE initial conditions. |
functionArguments |
Names passed to the model function. |
functionArgumentsSymbol |
Symbolic argument list for parsing. |
modelODE |
|
doseEvent |
Bolus dose event table passed to |
solverInputs |
Reserved; not used for bolus initial-condition dosing. |
An S7 object of class ModelODEBolus.
ModelODEBolus()ModelODEBolus()
ODE model with bolus dose terms inside the differential equations.
ModelODEDoseInEquations( name = character(0), modelParameters = list(), modelCovariatesEquation = NULL, modelCovariates = list(), covariatesEffect = list(), covariatesCombination = list(), modelParametersWithCovariates = list(), numberOfOccasions = 1, omegaWithIOV = numeric(0), samplings = numeric(0), modelEquations = list(), wrapper = NULL, outputFormula = list(), outputNames = character(0), variableNames = character(0), outcomesWithAdministration = character(0), outcomesWithNoAdministration = character(0), modelError = list(), odeSolverParameters = list(), parametersForComputingGradient = list(), initialConditions = numeric(0), functionArguments = character(0), functionArgumentsSymbol = list(), modelODEDoseInEquations = function() NULL, solverInputs = list() )ModelODEDoseInEquations( name = character(0), modelParameters = list(), modelCovariatesEquation = NULL, modelCovariates = list(), covariatesEffect = list(), covariatesCombination = list(), modelParametersWithCovariates = list(), numberOfOccasions = 1, omegaWithIOV = numeric(0), samplings = numeric(0), modelEquations = list(), wrapper = NULL, outputFormula = list(), outputNames = character(0), variableNames = character(0), outcomesWithAdministration = character(0), outcomesWithNoAdministration = character(0), modelError = list(), odeSolverParameters = list(), parametersForComputingGradient = list(), initialConditions = numeric(0), functionArguments = character(0), functionArgumentsSymbol = list(), modelODEDoseInEquations = function() NULL, solverInputs = list() )
name |
Model name. |
modelParameters |
List of |
modelCovariatesEquation |
|
modelCovariates |
List of covariate objects. |
covariatesEffect |
Nested covariate effect structure (internal). |
covariatesCombination |
Covariate combination table (internal). |
modelParametersWithCovariates |
Per-combination/occasion parameters (internal). |
numberOfOccasions |
Number of study occasions (set on the |
omegaWithIOV |
IIV/IOV variance vector for population FIM (internal). |
samplings |
Sampling times for the current arm. |
modelEquations |
Model equations (analytic or ODE). |
wrapper |
Compiled or R function wrapper for predictions. |
outputFormula |
Output expressions per outcome (character strings). |
outputNames |
Character vector of outcome names. |
variableNames |
State variable names. |
outcomesWithAdministration |
Outcomes linked to dosing. |
outcomesWithNoAdministration |
Outcomes without dosing. |
modelError |
List of residual error models. |
odeSolverParameters |
|
parametersForComputingGradient |
Internal FD stencil ( |
initialConditions |
ODE initial conditions. |
functionArguments |
Names passed to the model function. |
functionArgumentsSymbol |
Symbolic argument list for parsing. |
modelODEDoseInEquations |
|
solverInputs |
Per-outcome administration windows and dose levels. |
An S7 object of class ModelODEDoseInEquations.
ModelODEDoseInEquations()ModelODEDoseInEquations()
ODE model with bolus doses added as compartment events.
ModelODEDoseNotInEquations( name = character(0), modelParameters = list(), modelCovariatesEquation = NULL, modelCovariates = list(), covariatesEffect = list(), covariatesCombination = list(), modelParametersWithCovariates = list(), numberOfOccasions = 1, omegaWithIOV = numeric(0), samplings = numeric(0), modelEquations = list(), wrapper = NULL, outputFormula = list(), outputNames = character(0), variableNames = character(0), outcomesWithAdministration = character(0), outcomesWithNoAdministration = character(0), modelError = list(), odeSolverParameters = list(), parametersForComputingGradient = list(), initialConditions = numeric(0), functionArguments = character(0), functionArgumentsSymbol = list(), modelODE = function() NULL, doseEvent = list(), solverInputs = list() )ModelODEDoseNotInEquations( name = character(0), modelParameters = list(), modelCovariatesEquation = NULL, modelCovariates = list(), covariatesEffect = list(), covariatesCombination = list(), modelParametersWithCovariates = list(), numberOfOccasions = 1, omegaWithIOV = numeric(0), samplings = numeric(0), modelEquations = list(), wrapper = NULL, outputFormula = list(), outputNames = character(0), variableNames = character(0), outcomesWithAdministration = character(0), outcomesWithNoAdministration = character(0), modelError = list(), odeSolverParameters = list(), parametersForComputingGradient = list(), initialConditions = numeric(0), functionArguments = character(0), functionArgumentsSymbol = list(), modelODE = function() NULL, doseEvent = list(), solverInputs = list() )
name |
Model name. |
modelParameters |
List of |
modelCovariatesEquation |
|
modelCovariates |
List of covariate objects. |
covariatesEffect |
Nested covariate effect structure (internal). |
covariatesCombination |
Covariate combination table (internal). |
modelParametersWithCovariates |
Per-combination/occasion parameters (internal). |
numberOfOccasions |
Number of study occasions (set on the |
omegaWithIOV |
IIV/IOV variance vector for population FIM (internal). |
samplings |
Sampling times for the current arm. |
modelEquations |
Model equations (analytic or ODE). |
wrapper |
Compiled or R function wrapper for predictions. |
outputFormula |
Output expressions per outcome (character strings). |
outputNames |
Character vector of outcome names. |
variableNames |
State variable names. |
outcomesWithAdministration |
Outcomes linked to dosing. |
outcomesWithNoAdministration |
Outcomes without dosing. |
modelError |
List of residual error models. |
odeSolverParameters |
|
parametersForComputingGradient |
Internal FD stencil ( |
initialConditions |
ODE initial conditions. |
functionArguments |
Names passed to the model function. |
functionArgumentsSymbol |
Symbolic argument list for parsing. |
modelODE |
|
doseEvent |
Bolus dose event table passed to |
solverInputs |
Reserved; not used for compartment-event bolus dosing. |
An S7 object of class ModelODEDoseNotInEquations.
ModelODEDoseNotInEquations()ModelODEDoseNotInEquations()
ODE model with infusion inputs.
Inherits from ModelODE (numerical nature) rather than
ModelInfusion, so S7_inherits(x, ModelODE) is TRUE for
infusion ODEs. Use .pfimIsInfusionModel() for the infusion capability.
ModelODEInfusion( name = character(0), modelParameters = list(), modelCovariatesEquation = NULL, modelCovariates = list(), covariatesEffect = list(), covariatesCombination = list(), modelParametersWithCovariates = list(), numberOfOccasions = 1, omegaWithIOV = numeric(0), samplings = numeric(0), modelEquations = list(), wrapper = NULL, outputFormula = list(), outputNames = character(0), variableNames = character(0), outcomesWithAdministration = character(0), outcomesWithNoAdministration = character(0), modelError = list(), odeSolverParameters = list(), parametersForComputingGradient = list(), initialConditions = numeric(0), functionArguments = character(0), functionArgumentsSymbol = list() )ModelODEInfusion( name = character(0), modelParameters = list(), modelCovariatesEquation = NULL, modelCovariates = list(), covariatesEffect = list(), covariatesCombination = list(), modelParametersWithCovariates = list(), numberOfOccasions = 1, omegaWithIOV = numeric(0), samplings = numeric(0), modelEquations = list(), wrapper = NULL, outputFormula = list(), outputNames = character(0), variableNames = character(0), outcomesWithAdministration = character(0), outcomesWithNoAdministration = character(0), modelError = list(), odeSolverParameters = list(), parametersForComputingGradient = list(), initialConditions = numeric(0), functionArguments = character(0), functionArgumentsSymbol = list() )
name |
Model name. |
modelParameters |
List of |
modelCovariatesEquation |
|
modelCovariates |
List of covariate objects. |
covariatesEffect |
Nested covariate effect structure (internal). |
covariatesCombination |
Covariate combination table (internal). |
modelParametersWithCovariates |
Per-combination/occasion parameters (internal). |
numberOfOccasions |
Number of study occasions (set on the |
omegaWithIOV |
IIV/IOV variance vector for population FIM (internal). |
samplings |
Sampling times for the current arm. |
modelEquations |
Model equations (analytic or ODE). |
wrapper |
Compiled or R function wrapper for predictions. |
outputFormula |
Output expressions per outcome (character strings). |
outputNames |
Character vector of outcome names. |
variableNames |
State variable names. |
outcomesWithAdministration |
Outcomes linked to dosing. |
outcomesWithNoAdministration |
Outcomes without dosing. |
modelError |
List of residual error models. |
odeSolverParameters |
|
parametersForComputingGradient |
Internal FD stencil ( |
initialConditions |
ODE initial conditions. |
functionArguments |
Names passed to the model function. |
functionArgumentsSymbol |
Symbolic argument list for parsing. |
An S7 object of class ModelODEInfusion.
ModelODEInfusion()ModelODEInfusion()
ODE infusion model with dose terms in the equations.
ModelODEInfusionDoseInEquation( name = character(0), modelParameters = list(), modelCovariatesEquation = NULL, modelCovariates = list(), covariatesEffect = list(), covariatesCombination = list(), modelParametersWithCovariates = list(), numberOfOccasions = 1, omegaWithIOV = numeric(0), samplings = numeric(0), modelEquations = list(), wrapper = NULL, outputFormula = list(), outputNames = character(0), variableNames = character(0), outcomesWithAdministration = character(0), outcomesWithNoAdministration = character(0), modelError = list(), odeSolverParameters = list(), parametersForComputingGradient = list(), initialConditions = numeric(0), functionArguments = character(0), functionArgumentsSymbol = list(), modelODE = function() NULL, wrapperModelInfusion = list(), solverInputs = list() )ModelODEInfusionDoseInEquation( name = character(0), modelParameters = list(), modelCovariatesEquation = NULL, modelCovariates = list(), covariatesEffect = list(), covariatesCombination = list(), modelParametersWithCovariates = list(), numberOfOccasions = 1, omegaWithIOV = numeric(0), samplings = numeric(0), modelEquations = list(), wrapper = NULL, outputFormula = list(), outputNames = character(0), variableNames = character(0), outcomesWithAdministration = character(0), outcomesWithNoAdministration = character(0), modelError = list(), odeSolverParameters = list(), parametersForComputingGradient = list(), initialConditions = numeric(0), functionArguments = character(0), functionArgumentsSymbol = list(), modelODE = function() NULL, wrapperModelInfusion = list(), solverInputs = list() )
name |
Model name. |
modelParameters |
List of |
modelCovariatesEquation |
|
modelCovariates |
List of covariate objects. |
covariatesEffect |
Nested covariate effect structure (internal). |
covariatesCombination |
Covariate combination table (internal). |
modelParametersWithCovariates |
Per-combination/occasion parameters (internal). |
numberOfOccasions |
Number of study occasions (set on the |
omegaWithIOV |
IIV/IOV variance vector for population FIM (internal). |
samplings |
Sampling times for the current arm. |
modelEquations |
Model equations (analytic or ODE). |
wrapper |
Compiled or R function wrapper for predictions. |
outputFormula |
Output expressions per outcome (character strings). |
outputNames |
Character vector of outcome names. |
variableNames |
State variable names. |
outcomesWithAdministration |
Outcomes linked to dosing. |
outcomesWithNoAdministration |
Outcomes without dosing. |
modelError |
List of residual error models. |
odeSolverParameters |
|
parametersForComputingGradient |
Internal FD stencil ( |
initialConditions |
ODE initial conditions. |
functionArguments |
Names passed to the model function. |
functionArgumentsSymbol |
Symbolic argument list for parsing. |
modelODE |
An object |
wrapperModelInfusion |
Wrapper for solver. |
solverInputs |
A list with the solver inputs. |
An S7 object of class ModelODEInfusionDoseInEquation.
ModelODEInfusionDoseInEquation()ModelODEInfusionDoseInEquation()
One population model parameter: distribution (mu, omega), optional IOV (gamma), and fix flags.
ModelParameter( name = character(0), gamma = 0, distribution = NULL, fixedMu = FALSE, fixedOmega = FALSE, value = numeric(0) )ModelParameter( name = character(0), gamma = 0, distribution = NULL, fixedMu = FALSE, fixedOmega = FALSE, value = numeric(0) )
name |
Character string: name of the parameter. |
gamma |
Numeric: the SD for inter-occasion variability (IOV).
|
distribution |
An object of class |
fixedMu |
Logical: TRUE if |
fixedOmega |
Logical: TRUE if |
value |
Reserved (unused); use |
An S7 object of class ModelParameter.
ModelParameter(name = "Cl", distribution = LogNormal(mu = 1, omega = 0.3))ModelParameter(name = "Cl", distribution = LogNormal(mu = 1, omega = 0.3))
Multiplicative weight algorithm for optimal sampling-time allocation (Rcpp kernel).
Pass lambda, delta, numberOfIterations, and
weightThreshold via optimizerParameters on Optimization.
Outputs store two D-values: mixtureDcriterion is the D of the continuous
mixture over retained candidate cells; realisedDcriterion is the D of
the single protocol actually implemented. For joint multi-outcome cells (several
arms sharing one protocol in the constraint grid), only the best-weighted cell
is kept - mixture weights describe the optimisation simplex, not a multi-protocol
subject allocation across joint arms.
MultiplicativeAlgorithm(multiplicativeAlgorithmOutputs = list())MultiplicativeAlgorithm(multiplicativeAlgorithmOutputs = list())
multiplicativeAlgorithmOutputs |
Compact outputs after optimize
(retained |
A MultiplicativeAlgorithm specification object.
vignette("Vignette_01_discrete_design")vignette("Vignette_01_discrete_design")
Normal distribution for model parameters (identity link on the mean).
Normal(name = character(0), mu = 0, omega = 0)Normal(name = character(0), mu = 0, omega = 0)
name |
Character string: distribution label. |
mu |
Typical value on the natural (untransformed) scale. For
|
omega |
Standard deviation of random effects (IIV). |
An S7 object of class Normal.
Normal(mu = 0, omega = 1)Normal(mu = 0, omega = 1)
Design optimization: search over sampling times (or related design variables) using a metaheuristic or exchange algorithm.
Project fields use prop. Several designs: all optimizers
(discrete and continuous) optimize each in turn
(optimisationAlgorithmOutputs$perDesign).
Optimization( name = character(0), modelClass = character(0), modelEquations = list(), modelCovariatesEquation = character(0), modelFromLibrary = list(), modelParameters = list(), modelCovariates = list(), modelError = list(), optimizer = character(0), optimizerParameters = list(), outputs = list(), designs = list(), fimType = character(0), fim = NULL, odeSolverParameters = list(), numberOfOccasions = NA_real_, project = NULL, optimisationDesign = list(), optimisationAlgorithmOutputs = list() )Optimization( name = character(0), modelClass = character(0), modelEquations = list(), modelCovariatesEquation = character(0), modelFromLibrary = list(), modelParameters = list(), modelCovariates = list(), modelError = list(), optimizer = character(0), optimizerParameters = list(), outputs = list(), designs = list(), fimType = character(0), fim = NULL, odeSolverParameters = list(), numberOfOccasions = NA_real_, project = NULL, optimisationDesign = list(), optimisationAlgorithmOutputs = list() )
name |
Character string: project name. |
modelClass |
Model S7 class name; filled by |
modelEquations |
List of model equations (or empty if using the model library). |
modelCovariatesEquation |
Character: |
modelFromLibrary |
List selecting a built-in PK/PD model. |
modelParameters |
List of |
modelCovariates |
List of covariate objects (from |
modelError |
List of residual error model objects. |
optimizer |
Character: optimization algorithm name (for |
optimizerParameters |
See |
outputs |
Named list mapping internal to user output names. |
designs |
List of |
fimType |
Character: |
fim |
|
odeSolverParameters |
List with |
numberOfOccasions |
Integer number of study occasions; |
project |
Nested |
optimisationDesign |
List with initial and optimal design evaluations. |
optimisationAlgorithmOutputs |
Raw outputs from the optimization algorithm. |
An Optimization object; after run(), see
optimisationDesign and optimisationAlgorithmOutputs.
vignette("Vignette_01_discrete_design") source(system.file("examples", "evaluation-minimal.R", package = "PFIM")) class(ev)vignette("Vignette_01_discrete_design") source(system.file("examples", "evaluation-minimal.R", package = "PFIM")) class(ev)
Default built-in PD model library instance.
pdModelLibrarypdModelLibrary
An S7 object of class LibraryOfPDModels.
A LibraryOfPDModels object.
LibraryOfPDModels for the class constructor.
length(prop(pdModelLibrary, "models"))length(prop(pdModelLibrary, "models"))
Read a PFIM session option
pfim_get_option(name, default = NULL)pfim_get_option(name, default = NULL)
name |
Option name, with or without |
default |
Value when the option is unset. |
Option value.
pfim_set_option, pfim_reset_session
pfim_get_option("fim.cache.maxEntries")pfim_get_option("fim.cache.maxEntries")
List registered extensions
pfim_list_extensions()pfim_list_extensions()
A list of registered extension names.
pfim_list_extensions()pfim_list_extensions()
Extends PFIM with a new fimType string for Evaluation /
Optimization. The factory is called whenever a project needs a
fresh FIM of that type. Overwrites silently if name already exists.
pfim_register_fim_type(name, factory, duplicator = .fimDuplicateReset)pfim_register_fim_type(name, factory, duplicator = .fimDuplicateReset)
name |
Character label (e.g. |
factory |
Zero-argument function returning a |
duplicator |
Optional |
Invisibly, NULL.
source(system.file("examples", "evaluation-minimal.R", package = "PFIM")) # help(pfim_register_fim_type)source(system.file("examples", "evaluation-minimal.R", package = "PFIM")) # help(pfim_register_fim_type)
Register a model class
pfim_register_model_class(className, factory, detect = NULL)pfim_register_model_class(className, factory, detect = NULL)
className |
Character S7 class name (e.g. |
factory |
Zero-argument function returning a |
detect |
Optional |
Invisibly, NULL.
source(system.file("examples", "evaluation-minimal.R", package = "PFIM")) # help(pfim_register_model_class)source(system.file("examples", "evaluation-minimal.R", package = "PFIM")) # help(pfim_register_model_class)
Makes optimizer = name valid on Optimization. The factory
must return an S7 optimizer object with an optimizeDesign method.
Overwrites silently if name already exists.
pfim_register_optimizer(name, factory)pfim_register_optimizer(name, factory)
name |
Character optimizer name (e.g. |
factory |
Zero-argument function returning an optimizer object. |
Invisibly, NULL.
source(system.file("examples", "evaluation-minimal.R", package = "PFIM")) # help(pfim_register_optimizer)source(system.file("examples", "evaluation-minimal.R", package = "PFIM")) # help(pfim_register_optimizer)
Registered model class names
pfim_registered_model_classes() pfim_registered_fim_types() pfim_registered_optimizers()pfim_registered_model_classes() pfim_registered_fim_types() pfim_registered_optimizers()
A character vector of registered class names.
pfim_registered_model_classes() pfim_registered_fim_types() pfim_registered_optimizers()pfim_registered_model_classes() pfim_registered_fim_types() pfim_registered_optimizers()
Clears .pfimSession options and empties the design FIM cache
(.pfimFimDesignCache), covariate/occasion cache, eval-model rebuild cache,
and gradient/ODE performance caches (FD scheme, admin, ODE time grids).
Call between unrelated runs in a long-lived R session (Shiny, services).
pfim_reset_session(closeDevices = FALSE)pfim_reset_session(closeDevices = FALSE)
closeDevices |
Logical. If |
Invisibly NULL.
pfim_reset_session()pfim_reset_session()
Resolve model class name for a project
pfim_resolve_model_class(pfimproject)pfim_resolve_model_class(pfimproject)
pfimproject |
A |
Character class name with attribute source ("registry" or "legacy").
source(system.file("examples", "evaluation-minimal.R", package = "PFIM")) # help(pfim_resolve_model_class)source(system.file("examples", "evaluation-minimal.R", package = "PFIM")) # help(pfim_resolve_model_class)
Options apply for the current R session until pfim_reset_session.
pfim_set_option(...)pfim_set_option(...)
... |
Named option values. Common options:
|
Invisibly NULL.
pfim_get_option, pfim_reset_session
pfim_set_option(fim.cache.maxEntries = 2048L)pfim_set_option(fim.cache.maxEntries = 2048L)
Base S7 class for PFIM design evaluation and optimization projects.
Set numberOfOccasions on Evaluation or Optimization (optional:
NA infers from covariates and IOV). When set explicitly, it must match
inferNumberOfOccasions. The resolved value is stored on the
Model in defineModelType().
All fimType values support covariates and IOV; population adds
omega and gamma blocks to the FIM.
PFIMProject( name = character(0), modelClass = character(0), modelEquations = list(), modelCovariatesEquation = character(0), modelFromLibrary = list(), modelParameters = list(), modelCovariates = list(), modelError = list(), optimizer = character(0), optimizerParameters = list(), outputs = list(), designs = list(), fimType = character(0), fim = NULL, odeSolverParameters = list(), numberOfOccasions = NA_real_, cacheScope = "" )PFIMProject( name = character(0), modelClass = character(0), modelEquations = list(), modelCovariatesEquation = character(0), modelFromLibrary = list(), modelParameters = list(), modelCovariates = list(), modelError = list(), optimizer = character(0), optimizerParameters = list(), outputs = list(), designs = list(), fimType = character(0), fim = NULL, odeSolverParameters = list(), numberOfOccasions = NA_real_, cacheScope = "" )
name |
Character string: project name. |
modelClass |
Model S7 class name; filled by |
modelEquations |
List of model equations (or empty if using the model library). |
modelCovariatesEquation |
Character: |
modelFromLibrary |
List selecting a built-in PK/PD model. |
modelParameters |
List of |
modelCovariates |
List of covariate objects (from |
modelError |
List of residual error model objects. |
optimizer |
Character: optimization algorithm name (for |
optimizerParameters |
List of algorithm-specific settings passed to
|
outputs |
Named list mapping internal to user output names. |
designs |
List of |
fimType |
Character: |
fim |
|
odeSolverParameters |
List with |
numberOfOccasions |
Integer number of study occasions; |
cacheScope |
Reserved (internal FIM cache id). |
An S7 object of class PFIMProject.
PFIMProject(name = "demo")PFIMProject(name = "demo")
Population-based global optimization for sampling times (Rcpp kernel).
Pass N, muteEffect, maxIteration, purgeIteration, and
seed via optimizerParameters on Optimization.
muteEffect is an additive mutation scale in the same time unit as the
sampling windows (e.g. hours), not a ratio in .
Search starts from each outcome's initialSamplings; seed controls
mutation draws only.
Optional fitBase (default 0.03) and cauchyProb (default 0.8,
probability of a Cauchy jump vs Gaussian group mutation).
Optional tolerance (default 0, stall stop disabled ->
converged = NA) and stallIterations
(default 5) enable early stopping when tolerance > 0.
PGBOAlgorithm(optimizerOutputs = list())PGBOAlgorithm(optimizerOutputs = list())
optimizerOutputs |
List filled by |
A PGBOAlgorithm specification object.
vignette("Vignette_02_continuous_design")vignette("Vignette_02_continuous_design")
Default built-in PK model library instance.
pkModelLibrarypkModelLibrary
An S7 object of class LibraryOfPKModels.
A LibraryOfPKModels object.
LibraryOfPKModels for the class constructor.
length(prop(pkModelLibrary, "models"))length(prop(pkModelLibrary, "models"))
Plot evaluation outputs for a project
Predicted responses for the optimal design evaluation.
Predicted responses with sampling markers for all designs/arms.
plotEvaluation(pfimproject, ...)plotEvaluation(pfimproject, ...)
pfimproject |
A |
... |
Method-specific arguments. For |
A nested list of ggplot2 plot objects (by design / arm / outcome).
source(system.file("examples", "evaluation-minimal.R", package = "PFIM")) names(plotEvaluation(ev, list()))source(system.file("examples", "evaluation-minimal.R", package = "PFIM")) names(plotEvaluation(ev, list()))
Plot optimized sampling frequencies
Fedorov-Wynn optimal frequencies
plotFrequencies(optimization, ...)plotFrequencies(optimization, ...)
optimization |
An |
... |
Optional method arguments. |
A ggplot2 plot object.
source(system.file("examples", "evaluation-minimal.R", package = "PFIM")) # help(plotFrequencies)source(system.file("examples", "evaluation-minimal.R", package = "PFIM")) # help(plotFrequencies)
Plot relative standard errors for project results
RSE bar chart for the optimal design FIM.
RSE bar chart for the primary evaluation FIM.
plotRSE(pfimproject, ...)plotRSE(pfimproject, ...)
pfimproject |
A |
... |
Optional method arguments. |
A ggplot2 plot object.
source(system.file("examples", "evaluation-minimal.R", package = "PFIM")) inherits(plotRSE(ev), "ggplot")source(system.file("examples", "evaluation-minimal.R", package = "PFIM")) inherits(plotRSE(ev), "ggplot")
Plot standard errors for project results
SE bar chart for the optimal design FIM.
SE bar chart for the primary evaluation FIM.
plotSE(pfimproject, ...)plotSE(pfimproject, ...)
pfimproject |
A |
... |
Optional method arguments. |
A ggplot2 plot object.
source(system.file("examples", "evaluation-minimal.R", package = "PFIM")) inherits(plotSE(ev), "ggplot")source(system.file("examples", "evaluation-minimal.R", package = "PFIM")) inherits(plotSE(ev), "ggplot")
Plot sensitivity indices for a project
Sensitivity-index plots for the optimal design evaluation.
Sensitivity indices over time for all designs/arms.
plotSensitivityIndices(pfimproject, ...)plotSensitivityIndices(pfimproject, ...)
pfimproject |
A |
... |
Method-specific arguments. For |
A ggplot2 plot object.
source(system.file("examples", "evaluation-minimal.R", package = "PFIM")) names(plotSensitivityIndices(ev, list()))source(system.file("examples", "evaluation-minimal.R", package = "PFIM")) names(plotSensitivityIndices(ev, list()))
Plot Bayesian shrinkage from a FIM
Default method for BayesianFim.
plotShrinkage(fim, evaluation, ...)plotShrinkage(fim, evaluation, ...)
fim |
First argument of generic. |
evaluation |
|
... |
Graphics parameters passed to |
ggplot object showing Bayesian shrinkage by parameter.
source(system.file("examples", "covariate-test-minimal.R", package = "PFIM")) prop(ev, "fimType") = "Bayesian" ev = run(ev) plotShrinkage(prop(ev, "fim"), ev)source(system.file("examples", "covariate-test-minimal.R", package = "PFIM")) prop(ev, "fimType") = "Bayesian" ev = run(ev) plotShrinkage(prop(ev, "fim"), ev)
Plot optimized arm weights
Multiplicative algorithm weights by iteration
plotWeights(optimization, ...)plotWeights(optimization, ...)
optimization |
An |
... |
Optional method arguments. |
A ggplot2 plot object.
source(system.file("examples", "evaluation-minimal.R", package = "PFIM")) # help(plotWeights)source(system.file("examples", "evaluation-minimal.R", package = "PFIM")) # help(plotWeights)
Population Fisher information matrix for nonlinear mixed-effects models.
PopulationFim( fisherMatrix = numeric(0), fixedEffects = numeric(0), varianceEffects = numeric(0), SEAndRSE = list(), condNumberFixedEffects = 0, condNumberVarianceEffects = 0, shrinkage = numeric(0), singularFim = FALSE )PopulationFim( fisherMatrix = numeric(0), fixedEffects = numeric(0), varianceEffects = numeric(0), SEAndRSE = list(), condNumberFixedEffects = 0, condNumberVarianceEffects = 0, shrinkage = numeric(0), singularFim = FALSE )
fisherMatrix |
Labelled FIM matrix. |
fixedEffects |
Fixed-effects sub-block. |
varianceEffects |
Variance-effects sub-block. |
SEAndRSE |
List with |
condNumberFixedEffects |
Condition number of the fixed-effects block. |
condNumberVarianceEffects |
Condition number of the variance-effects block. |
shrinkage |
Named shrinkage (percent) per parameter (Bayesian FIM). |
singularFim |
|
The population FIM has fixed-effects (, ) and variance-effects
(, , ) blocks:
where is the arm size and .
A PopulationFim object (filled by run()).
source(system.file("examples", "evaluation-minimal.R", package = "PFIM")) S7::S7_inherits(prop(ev, "fim"), PopulationFim)source(system.file("examples", "evaluation-minimal.R", package = "PFIM")) S7::S7_inherits(prop(ev, "fim"), PopulationFim)
PFIMProject for an Optimization
Nested PFIMProject for an Optimization
projectOf(x)projectOf(x)
x |
An |
The underlying PFIMProject.
source(system.file("examples", "evaluation-minimal.R", package = "PFIM")) projectOf(ev)source(system.file("examples", "evaluation-minimal.R", package = "PFIM")) projectOf(ev)
Read a project field
Write a project field
projectProp(x, name) projectProp(x, name) <- value projectProp(x, name) <- valueprojectProp(x, name) projectProp(x, name) <- value projectProp(x, name) <- value
x |
An |
name |
Character name of the project property. |
value |
Value to assign. |
The requested project property value, or the modified object for replacement.
source(system.file("examples", "evaluation-minimal.R", package = "PFIM")) projectProp(ev, "name") projectProp(ev, "name") = "renamed"source(system.file("examples", "evaluation-minimal.R", package = "PFIM")) projectProp(ev, "name") projectProp(ev, "name") = "renamed"
Optimization read slot project.Property accessor (S7); project fields on Optimization read slot project.
prop(object, name) prop(object, name) <- value prop(object, name) <- valueprop(object, name) prop(object, name) <- value prop(object, name) <- value
object |
An S7 object. |
name |
Property name. |
value |
Value to assign. |
The requested property value, or the modified object for replacement.
source(system.file("examples", "evaluation-minimal.R", package = "PFIM")) prop(ev, "name") prop(ev, "name") = "renamed"source(system.file("examples", "evaluation-minimal.R", package = "PFIM")) prop(ev, "name") prop(ev, "name") = "renamed"
Pure proportional residual error: V = (sigmaSlope * f^{cError})^2
(combined1 with sigmaInter locked to 0).
Proportional( output = character(0), sigmaInter = 0, sigmaSlope = 0, sigmaInterFixed = FALSE, sigmaSlopeFixed = FALSE, cError = 1, ... )Proportional( output = character(0), sigmaInter = 0, sigmaSlope = 0, sigmaInterFixed = FALSE, sigmaSlopeFixed = FALSE, cError = 1, ... )
output |
Outcome name. |
sigmaInter |
Additive residual SD. |
sigmaSlope |
Proportional residual SD. |
sigmaInterFixed |
If |
sigmaSlopeFixed |
If |
cError |
Power on the proportional prediction term. |
... |
Legacy |
An S7 object of class Proportional.
Proportional(output = "RespPK", sigmaSlope = 0.15)Proportional(output = "RespPK", sigmaSlope = 0.15)
Particle Swarm Optimization for sampling-time search (Rcpp kernel in src/PSOKernel.cpp).
Pass maxIteration, populationSize, seed, and learning coefficients
via optimizerParameters on Optimization.
Search starts from each outcome's initialSamplings (reported initial design);
seed controls swarm exploration after that start.
Optional tolerance (default 0, stall stop disabled ->
converged = NA) and stallIterations
(default 5) enable early stopping when tolerance > 0.
PSOAlgorithm(optimizerOutputs = list())PSOAlgorithm(optimizerOutputs = list())
optimizerOutputs |
List filled by |
A PSOAlgorithm specification object.
vignette("Vignette_02_continuous_design")vignette("Vignette_02_continuous_design")
Requires rmarkdown and pandoc (https://pandoc.org).
Rebuilds kable tables and plots for both the initial and optimal evaluations,
then hands everything to generateReportOptimization() with the FIM-type
R Markdown template.
Assembles model / design / FIM kables and response / SI / SE / RSE plots, then
dispatches to the FIM-type R Markdown template via
generateReportEvaluation().
Administration / initial-design tables use design 1 only; response and SI
plots cover every design in designs.
Report(pfimproject, ...)Report(pfimproject, ...)
pfimproject |
A |
... |
|
Invisibly, the path or result from the report generator.
if (rmarkdown::pandoc_available()) { source(system.file("examples", "evaluation-minimal.R", package = "PFIM")) tmp = tempfile(fileext = ".html") Report(ev, outputPath = tempdir(), outputFile = basename(tmp), plotOptions = list()) }if (rmarkdown::pandoc_available()) { source(system.file("examples", "evaluation-minimal.R", package = "PFIM")) tmp = tempfile(fileext = ".html") Report(ev, outputPath = tempdir(), outputFile = basename(tmp), plotOptions = list()) }
Pipeline: set FIM cache scope -> rebuild model (with finite differences) ->
instantiate FIM type -> evaluateDesign() per design -> post-process the
primary FIM via setEvaluationFim(). Additional designs remain in
evaluationDesign; use getEvaluationDesign() to retrieve them.
Pipeline: invalidate model cache -> instantiate algorithm -> define FIM ->
resolve library equations if needed -> optimizeDesign(). Results land
in optimisationDesign (initial + optimal evaluations) and
optimisationAlgorithmOutputs.
run(pfimproject, ...)run(pfimproject, ...)
pfimproject |
An |
... |
Optional method arguments. |
The same Evaluation with evaluationDesign and fim updated.
The same Optimization with optimal design evaluations stored.
source(system.file("examples", "evaluation-minimal.R", package = "PFIM")) getDeterminant(ev) source(system.file("examples", "evaluation-minimal.R", package = "PFIM")) vignette("Vignette_01_discrete_design")source(system.file("examples", "evaluation-minimal.R", package = "PFIM")) getDeterminant(ev) source(system.file("examples", "evaluation-minimal.R", package = "PFIM")) vignette("Vignette_01_discrete_design")
Constraints on sampling times for design optimization (windows, fixed times, number of points to optimize, minimum spacing).
Metaheuristics (Simplex / PSO / PGBO) draw candidates with
generateSamplingsFromSamplingConstraints() and reject infeasible ones
via checkSamplingTimeConstraintsForMetaheuristic(). Discrete algorithms
instead enumerate combinations with generateSamplingTimesCombination().
SamplingTimeConstraints( outcome = character(0), initialSamplings = numeric(0), fixedTimes = numeric(0), numberOfsamplingsOptimisable = 0, numberOfSamplingsOptimisable = NULL, samplingsWindows = list(), numberOfTimesByWindows = numeric(0), minSampling = numeric(0) )SamplingTimeConstraints( outcome = character(0), initialSamplings = numeric(0), fixedTimes = numeric(0), numberOfsamplingsOptimisable = 0, numberOfSamplingsOptimisable = NULL, samplingsWindows = list(), numberOfTimesByWindows = numeric(0), minSampling = numeric(0) )
outcome |
Character string: outcome name. |
initialSamplings |
Initial sampling-time vector. Continuous
optimizers start from this vector (not from |
fixedTimes |
Times that must remain fixed during optimization. |
numberOfsamplingsOptimisable |
Total protocol size including
|
numberOfSamplingsOptimisable |
Alias of |
samplingsWindows |
List of time windows, in increasing time order. |
numberOfTimesByWindows |
Number of samples per window. |
minSampling |
Minimum spacing between consecutive samples. |
An S7 object of class SamplingTimeConstraints.
SamplingTimeConstraints( outcome = "RespPK", initialSamplings = c(0.5, 2, 8), numberOfsamplingsOptimisable = 2 )SamplingTimeConstraints( outcome = "RespPK", initialSamplings = c(0.5, 2, 8), numberOfsamplingsOptimisable = 2 )
Observation times for one outcome within an arm.
Times are in the model's time unit (often hours). Multiple
SamplingTimes objects on an arm cover multi-response designs.
SamplingTimes(outcome = character(0), samplings = numeric(0))SamplingTimes(outcome = character(0), samplings = numeric(0))
outcome |
Character string: outcome name. |
samplings |
Numeric vector: sampling times (hours or model time unit). |
An S7 object of class SamplingTimes.
SamplingTimes(outcome = "RespPK", samplings = c(1, 4, 8))SamplingTimes(outcome = "RespPK", samplings = c(1, 4, 8))
Save covariate test results to a text file
saveCovariateTest(relevanceResults, fileName, folder = NULL, tests = NULL)saveCovariateTest(relevanceResults, fileName, folder = NULL, tests = NULL)
relevanceResults |
A |
fileName |
Output file name (or full path when |
folder |
Optional directory; created if missing. |
tests |
Optional character vector overriding |
Invisibly, the output file path.
source(system.file("examples", "evaluation-minimal.R", package = "PFIM")) # help(saveCovariateTest)source(system.file("examples", "evaluation-minimal.R", package = "PFIM")) # help(saveCovariateTest)
Print FIM summaries to the console
Print FIM summaries to the console
Print FIM summaries to the console
Print FIM summaries to the console
showFIM(fim, ...)showFIM(fim, ...)
fim |
A |
... |
Not used by current methods. |
Invisibly, the input Fim object.
source(system.file("examples", "evaluation-minimal.R", package = "PFIM")) showFIM(prop(ev, "fim"))source(system.file("examples", "evaluation-minimal.R", package = "PFIM")) showFIM(prop(ev, "fim"))
Nelder-Mead (amoeba) optimization for sampling times (Rcpp kernel).
Pass pctInitialSimplexBuilding, tolerance, and maxIteration
via optimizerParameters on Optimization.
Search starts from each outcome's initialSamplings (same flat layout as PSO/PGBO).
Extra vertices move one coordinate toward the far end of its sampling window
(not toward 0), so unequal numberOfTimesByWindows stays feasible.
Infeasible initialSamplings are replaced by a feasible window start
with a warning.
tolerance <= 0 disables the relative stop (converged = NA, no warning),
matching PSO/PGBO when stall stop is off.
SimplexAlgorithm(optimizerOutputs = list())SimplexAlgorithm(optimizerOutputs = list())
optimizerOutputs |
List filled by |
A SimplexAlgorithm specification object.
vignette("Vignette_02_continuous_design")vignette("Vignette_02_continuous_design")