getData | Get a description of the data used in the current project. |
getStructuralModel | Get the model file for the structural model used in the current project. |
loadProject | Load a project by parsing the mlxtran-formated file whose path has been given as an input. |
newProject | Create a new empty project providing model and data specification. |
saveProject | Save the current project as an Mlxtran-formated file. |
setData | Set project data giving a data file and specifying headers and observations types. |
setStructuralModel | Set the structural model. |
Get project data
Description
Get a description of the data used in the current project. Available information are:
- dataFile (string): path to the data file
- header (array<character>): vector of header names
- headerTypes (array<character>): vector of header types
- observationNames (vector<string>): vector of observation names
- observationTypes (vector<string>): vector of observation types
- nbSSDoses (int) : number of doses (if there is a SS column)
Usage
getData()
Value
A list describing project data.
See Also
Click here to see examples
## Not run: data = getData() data -> $dataFile "/path/to/data/file.txt" $header c("ID","TIME","CONC","SEX","OCC") $headerTypes c("ID","TIME","OBSERVATION","CATEGORICAL COVARIATE","IGNORE") $observationNames c("concentration") $observationTypes c(concentration = "continuous") ## End(Not run)
Top of the page, Monolix-R functions.
Get structural model file
Description
Get the model file for the structural model used in the current project.
Usage
getStructuralModel()
Value
A string corresponding to the path to the structural model file.
See Also
Click here to see examples
## Not run: getStructuralModel() => "/path/to/model/inclusion/modelFile.txt" ## End(Not run)
Top of the page, Monolix-R functions.
Load project from file
Description
Load a project by parsing the mlxtran-formated file whose path has been given as an input.
WARNING: R is sensitive between ‘\’ and ‘/’, only ‘/’ can be used
Usage
loadProject(projectFile)
Arguments
projectFile
(character) Path to the project file. Can be absolute or relative to the current working directory.
See Also
Click here to see examples
## Not run: loadProject("/path/to/project/file.mlxtran") for Linux platform loadProject("C:/Users/path/to/project/file.mlxtran") for Windows platform ## End(Not run)
Top of the page, Monolix-R functions.
Create new project
Description
Create a new empty project providing model and data specification. The data specification is:
- dataFile (string): path to the data file
- headerTypes (array<character>): A vector of header types.
The possible header types are: “id”, “time”, “observation”, “amount”, “contcov”, “catcov”, “occ”, “evid”, “mdv”, “obsid”, “cens”, “limit”, “regressor”,”admid”, “rate”, “tinf”, “ss”, “ii”, “addl”, “date”, “ignore”.
Notice that these are not the types displayed in the interface, these one are shortcuts. They are not case-sensitive. - observationTypes (list): A list giving the type of each observation present in the data file. If there is only one y-type, the corresponding observation name can be omitted.
The possible observation types are “continuous”, “discrete”, and “event”. - nbSSDoses [optional](int): Number of doses (if there is a SS column).
- mapping [optional](list): a list giving the observation name associated to each y-type present in the data file (this field is mandatory when there is a column tagged with the “obsid” headerType)
Usage
newProject(modelFile, data)
Arguments
modelFile
(character) Path to the model file. Can be absolute or relative to the current working directory.
data
(list) Structure describing the data.
See Also
Click here to see examples
## Not run: newProject(data = list(dataFile = "/path/to/data/file.txt", headerTypes = c("IGNORE","OBSERVATION"), observationTypes = "continuous"), modelFile = "/path/to/model/file.txt") ## End(Not run) ## Example with warfarin_data.txt from demos and oral1_1cpt_kaVCl.txt from libraries in the current directory data = list(dataFile= "./warfarin_data.txt", headerTypes =c("id", "time", "amount", "observation", "obsid", "contcov", "catcov", "ignore"), observationTypes = list(y1 = "continuous", y2 = "continuous" ), mapping = list("1" = "y1", "2" = "y2")) modelFile <- './oral1_1cpt_kaVCl.txt' newProject(modelFile = modelFile, data = data)
Top of the page, Monolix-R functions.
Save current project
Description
Save the current project as an Mlxtran-formated file.
Usage
saveProject(projectFile = "")
Arguments
projectFile
<a href="character“>optional Path where to save a copy of the current mlxtran model. Can be absolute or relative to the current working directory.
If no path is given, the file used to build the current configuration is updated.
See Also
Click here to see examples
## Not run: saveProject("/path/to/project/file.mlxtran") # save a copy of the model saveProject() # update current model ## End(Not run)
Top of the page, Monolix-R functions.
Set project data
Description
Set project data giving a data file and specifying headers and observations types.
Usage
setData(dataFile, headerTypes, observationTypes, nbSSDoses = NULL)
Arguments
dataFile
(character): Path to the data file. Can be absolute or relative to the current working directory.
headerTypes
(array<character>): A collection of header types.
The possible header types are: “id”, “time”, “observation”, “amount”, “contcov”, “catcov”, “occ”, “evid”, “mdv”, “obsid”, “cens”, “limit”, “regressor”,”admid”, “rate”, “tinf”, “ss”, “ii”, “addl”, “date”, “ignore”
Notice that these are not the types displayed in the interface, these one are shortcuts. They are not case-sensitive.
observationTypes
(list): A list giving the type of each observation present in the data file. If there is only one y-type, the corresponding observation name can be omitted.
The possible observation types are “continuous”, “discrete”, and “event”
nbSSDoses
<a href="int“>optional: Number of doses (if there is a SS column).
See Also
Click here to see examples
## Not run: setData(dataFile = "/path/to/data/file.txt", headerTypes = c("IGNORE","OBSERVATION"), observationTypes = "continuous") setData(dataFile = "/path/to/data/file.txt", headerTypes = c("IGNORE", "OBSERVATION", "YTYPE"), observationTypes = list(Concentration = "continuous", Level = "discrete")) ## End(Not run)
Top of the page, Monolix-R functions.
Set structural model file
Description
Set the structural model.
Usage
setStructuralModel(modelFile)
Arguments
modelFile
(character) Path to the model file. Can be absolute or relative to the current working directory.
See Also
Click here to see examples
## Not run: setStructuralModel("/path/to/model/file.txt") ## End(Not run)
Top of the page, Monolix-R functions.