readMLX {REMixed}R Documentation

Extract Data for REMixed Algorithm from a Monolix Project

Description

This function retrieves all necessary information from a Monolix project file to format the input for the REMixed package. It gathers all relevant data required for the REMix algorithm.

Usage

readMLX(project = NULL, ObsModel.transfo, alpha)

Arguments

project

directory of the Monolix project (in .mlxtran). If NULL, the current loaded project is used (default is NULL).

ObsModel.transfo

list containing two lists of transformations and two vectors linking each transformations to their observation model name in the Monolix project. The list should include identity transformations and be named S and R. The two vectors should be named linkS and linkR.

Both S (for the direct observation models) and linkS, as well as R (for latent process models) and linkR, must have the same length.

  • S: a list of transformations for the direct observation models. Each transformation corresponds to a variable Y_p=h_p(S_p), where the name indicates which dynamic is observed (from dynFUN);

  • linkS : a vector specifying the observation model names (that is used in the monolix project, alpha1, etc.) for each transformation, in the same order as in S;

  • R: similarly, a list of transformations for the latent process models. Although currently there is only one latent dynamic, each s_k, k\leq K transformation corresponds to the same dynamic but may vary for each Y_k observed. The names should match the output from dynFUN;

  • linkR : a vector specifying the observation model names for each transformation, in the same order as in R.

alpha

named list of named vector "alpha0", "alpha1" (all alpha1 are mandatory). The names of alpha$alpha0 and alpha$alpha1 are the observation model names from the monolix project to which they are linked (if the observations models are defined whithout intercept, alpha$alpha0 need to be set to the vector NULL).

Details

To simplify its use, functions remix, cv.remix, gh.LL can be used with arguments data rather than all necessary informations "theta", "alpha1", "covariates", "ParModel.transfo", "ParModel.transfo.inv", "Sobs", "Robs", "Serr", "Rerr", "ObsModel.transfo" that could be extract from a monolix project. If the SAEM task of the project hasn't been launched, it's the initial condition and not the estimated parameters that are returned. If the conditional distribution estimation task has been launched, parameters "mu" and "Omega" are returned too.

Value

A list containing parameters, transformations, and observations from the Monolix project in the format needed for the REMixed algorithm :

See Also

remix, cv.remix.

Examples

## Not run: 
project <- getMLXdir()

ObsModel.transfo = list(S=list(AB=log10),
                        linkS="yAB",
                        R=rep(list(S=function(x){x}),5),
                        linkR = paste0("yG",1:5))

alpha=list(alpha0=NULL,
           alpha1=setNames(paste0("alpha_1",1:5),paste0("yG",1:5)))

res <- readMLX(project,ObsModel.transfo,alpha)

## End(Not run)

[Package REMixed version 0.1.0 Index]