LikGradHess.CM {flexmsm} | R Documentation |
Likelihood, gradient and Hessian for univariate transition intensity based models for the base dependence model.
Description
Likelihood, gradient and Hessian for univariate transition intensity based models for the base dependence model.
Usage
LikGradHess.CM(
params,
data = NULL,
full.X = NULL,
MM,
pen.matr.S.lambda,
aggregated.provided = FALSE,
do.gradient = TRUE,
do.hessian = TRUE,
pmethod = "analytic",
death,
Qmatr.diagnostics.list = NULL,
verbose = FALSE,
parallel = FALSE,
no_cores = 2,
CM.comp = TRUE,
P.save.all = FALSE
)
Arguments
params |
Parameters vector. |
data |
Dataset in proper format. |
full.X |
Full design matrix. |
MM |
List of necessary setup quantities. |
pen.matr.S.lambda |
Penalty matrix multiplied by smoothing parameter lambda. |
aggregated.provided |
Whether aggregated form was provided (may become obsolete in the future if we see original dataset as special case of aggregated where |
do.gradient |
Whether or not to compute the gradient. |
do.hessian |
Whether or not to compute the Hessian. |
pmethod |
Method to be used for computation of transition probability matrix. See help of |
death |
Whether the last state is an absorbing state. |
Qmatr.diagnostics.list |
List of maximum absolute values of the Q matrices computed during model fitting. |
verbose |
Whether to print out the progress being made in computing the likelihood, gradient and Hessian. |
parallel |
Whether or not to use parallel computing (only for Windows users for now). |
no_cores |
Number of cores used if parallel computing chosen. The default is 2. If |
CM.comp |
If |
P.save.all |
If |
Value
Penalized likelihood, gradient and Hessian associated with model at given parameters, for use by trust region algorithm.