addMixture
[Monolix] Add latent covariate to the model for a finite mixture model
Add a new latent covariate to the current model giving its name and its modality number (how many subpopulations).
Usage
addMixture(...)
Arguments
- ...
A list of comma-separated pairs
latentCovariateName = modalityNumber
, where modalityNumber is an integer
See also
getCovariateInformation
get current covariates in the model addContinuousTransformedCovariate
to add a transformation of a continuous covariate addCategoricalTransformedCovariate
to add a transformation of a categorical covariate removeCovariate
to remove added covariates
Examples
initializeLixoftConnectors("monolix")
#> [INFO] The library lixoftConnectors ("C:\Program Files\Lixoft\MonolixSuite2024R1\lib\lixoftConnectors.dll") is already loaded and initialized for monolix software -> nothing to be done.
project_file <- file.path(getDemoPath(), "5.models_for_individual_parameters", "5.3.mixture_of_distributions", "PKgroup_project.mlxtran")
loadProject(project_file)
addMixture(lcat = 2)
getCovariateInformation()
#> $modalityNumber
#> lcat
#> 2
#>
#> $name
#> [1] "GROUP" "lcat"
#>
#> $type
#> GROUP lcat
#> "categorical" "latent"
#>
#> $categories
#> $categories$GROUP
#> [1] "0" "1"
#>
#>
#> $covariate
#> id GROUP
#> 1 1 1
#> 2 2 0
#> 3 3 1
#> 4 4 0
#> 5 5 1
#> 6 6 0
#> 7 7 1
#> 8 8 0
#> 9 9 1
#> 10 10 0
#> 11 11 1
#> 12 12 0
#> 13 13 1
#> 14 14 0
#> 15 15 1
#> 16 16 0
#> 17 17 1
#> 18 18 0
#> 19 19 1
#> 20 20 0
#> 21 21 1
#> 22 22 0
#> 23 23 1
#> 24 24 0
#> 25 25 1
#> 26 26 0
#> 27 27 1
#> 28 28 0
#> 29 29 1
#> 30 30 0
#> 31 31 1
#> 32 32 0
#> 33 33 1
#> 34 34 0
#> 35 35 1
#> 36 36 0
#> 37 37 1
#> 38 38 0
#> 39 39 1
#> 40 40 0
#> 41 41 1
#> 42 42 0
#> 43 43 1
#> 44 44 0
#> 45 45 1
#> 46 46 0
#> 47 47 1
#> 48 48 0
#> 49 49 1
#> 50 50 0
#> 51 51 1
#> 52 52 0
#> 53 53 1
#> 54 54 0
#> 55 55 1
#> 56 56 0
#> 57 57 1
#> 58 58 0
#> 59 59 1
#> 60 60 0
#> 61 61 1
#> 62 62 0
#> 63 63 1
#> 64 64 0
#> 65 65 1
#> 66 66 0
#> 67 67 1
#> 68 68 0
#> 69 69 1
#> 70 70 0
#> 71 71 1
#> 72 72 0
#> 73 73 1
#> 74 74 0
#> 75 75 1
#> 76 76 0
#> 77 77 1
#> 78 78 0
#> 79 79 1
#> 80 80 0
#> 81 81 0
#> 82 82 0
#> 83 83 0
#> 84 84 0
#> 85 85 0
#> 86 86 0
#> 87 87 0
#> 88 88 0
#> 89 89 0
#> 90 90 0
#> 91 91 0
#> 92 92 0
#> 93 93 0
#> 94 94 0
#> 95 95 0
#> 96 96 0
#> 97 97 0
#> 98 98 0
#> 99 99 0
#> 100 100 0
#>