From ba9b5db7154fee265b1d60b3fdcd9081d83f4c83 Mon Sep 17 00:00:00 2001 From: levenc Date: Tue, 27 Aug 2024 09:42:15 +0200 Subject: [PATCH] use rxode2 model functions in the documentation --- NAMESPACE | 3 - NEWS.md | 3 + R/dosing_optim.R | 210 ++++----- R/input_validation.R | 2 +- R/iov.R | 2 +- R/ofv.R | 2 +- R/param_estim.R | 210 ++++----- R/posologyr.R | 2 +- R/residual_error.R | 8 +- R/utils.R | 2 +- README.Rmd | 24 +- README.md | 44 +- _pkgdown.yml | 35 +- docs/404.html | 24 +- docs/LICENSE.html | 20 +- docs/articles/a_posteriori_dosing.html | 114 ++--- docs/articles/a_priori_dosing.html | 104 +++-- docs/articles/auc_based_dosing.html | 112 ++--- docs/articles/classic_posologyr_models.html | 430 ++++++++++++++++++ docs/articles/index.html | 26 +- docs/articles/multiple_endpoints.html | 166 ++++--- docs/articles/patient_data.html | 290 ++++++++++++ docs/articles/patient_data_input.html | 22 +- docs/articles/population_models.html | 319 +++++++++++++ docs/articles/route_of_administration.html | 32 +- docs/authors.html | 20 +- docs/index.html | 46 +- docs/news/index.html | 27 +- docs/pkgdown.yml | 7 +- docs/reference/error_model_comb1.html | 20 +- docs/reference/error_model_comb2.html | 20 +- docs/reference/error_model_mixednm.html | 20 +- docs/reference/index.html | 51 +-- docs/reference/poso_dose_auc.html | 82 ++-- docs/reference/poso_dose_conc.html | 82 ++-- docs/reference/poso_estim_map.html | 101 ++-- docs/reference/poso_estim_mcmc.html | 124 ++--- docs/reference/poso_estim_sir.html | 124 ++--- docs/reference/poso_inter_cmin.html | 82 ++-- docs/reference/poso_simu_pop.html | 124 ++--- docs/reference/poso_time_cmin.html | 82 ++-- docs/reference/posologyr_error_lines.html | 20 +- docs/search.json | 2 +- docs/sitemap.xml | 4 +- man/error_model_comb1.Rd | 1 + man/error_model_comb2.Rd | 1 + man/error_model_mixednm.Rd | 1 + man/poso_dose_auc.Rd | 58 ++- man/poso_dose_conc.Rd | 58 ++- man/poso_estim_map.Rd | 52 +-- man/poso_estim_mcmc.Rd | 52 +-- man/poso_estim_sir.Rd | 52 +-- man/poso_inter_cmin.Rd | 58 ++- man/poso_simu_pop.Rd | 52 +-- man/poso_time_cmin.Rd | 58 ++- vignettes/a_posteriori_dosing.Rmd | 64 +-- vignettes/a_priori_dosing.Rmd | 64 +-- vignettes/auc_based_dosing.Rmd | 62 +-- ...odels.Rmd => classic_posologyr_models.Rmd} | 94 ++-- vignettes/multiple_endpoints.Rmd | 124 +++-- ...atient_data_input.Rmd => patient_data.Rmd} | 7 +- vignettes/population_models.Rmd | 195 ++++++++ vignettes/route_of_administration.Rmd | 8 +- 63 files changed, 2815 insertions(+), 1490 deletions(-) create mode 100644 docs/articles/classic_posologyr_models.html create mode 100644 docs/articles/patient_data.html create mode 100644 docs/articles/population_models.html rename vignettes/{posologyr_user_defined_models.Rmd => classic_posologyr_models.Rmd} (59%) rename vignettes/{patient_data_input.Rmd => patient_data.Rmd} (94%) create mode 100644 vignettes/population_models.Rmd diff --git a/NAMESPACE b/NAMESPACE index cfcbf5e..673da1e 100644 --- a/NAMESPACE +++ b/NAMESPACE @@ -4,9 +4,6 @@ S3method(posologyr_error_lines,default) S3method(posologyr_error_lines,norm) S3method(posologyr_error_lines,rxUi) S3method(posologyr_error_lines,t) -export(error_model_comb1) -export(error_model_comb2) -export(error_model_mixednm) export(poso_dose_auc) export(poso_dose_conc) export(poso_estim_map) diff --git a/NEWS.md b/NEWS.md index 275a183..29d49a7 100644 --- a/NEWS.md +++ b/NEWS.md @@ -6,6 +6,9 @@ ## Documentation * The README illustrates a simple example of dose adaptation * `vignette("route_of_administration")` shows how to select a route of administration for optimal dosing +* `vignette("population_models")` describes the structure of prior population models written as model functions which can be parsed by `rxode2` and used by `posologyr` +* `vignette("posologyr_user_defined_models")` is renamed `vignette("classic_posologyr_models")` +* Examples use `rxode2` model functions ## Bug fix * Fix a bug where `poso_estim_map()`, `poso_estim_sir()` and `poso_simu_pop()` failed for models featuring a single parameter with IIV. diff --git a/R/dosing_optim.R b/R/dosing_optim.R index 2dc3d55..dd0f106 100644 --- a/R/dosing_optim.R +++ b/R/dosing_optim.R @@ -1,5 +1,5 @@ #------------------------------------------------------------------------- -# posologyr: individual dose optimisation using population PK +# posologyr: individual dose optimization using population PK # Copyright (C) Cyril Leven # # This program is free software: you can redistribute it and/or modify @@ -100,37 +100,33 @@ #' rxode2::setRxThreads(2L) # limit the number of threads #' #' # model -#' mod_run001 <- list( -#' ppk_model = rxode2::rxode({ -#' centr(0) = 0; -#' depot(0) = 0; +#' mod_run001 <- function() { +#' ini({ +#' THETA_Cl <- 4.0 +#' THETA_Vc <- 70.0 +#' THETA_Ka <- 1.0 +#' ETA_Cl ~ 0.2 +#' ETA_Vc ~ 0.2 +#' ETA_Ka ~ 0.2 +#' prop.sd <- sqrt(0.05) +#' }) +#' model({ +#' TVCl <- THETA_Cl +#' TVVc <- THETA_Vc +#' TVKa <- THETA_Ka #' -#' TVCl = THETA_Cl; -#' TVVc = THETA_Vc; -#' TVKa = THETA_Ka; +#' Cl <- TVCl*exp(ETA_Cl) +#' Vc <- TVVc*exp(ETA_Vc) +#' Ka <- TVKa*exp(ETA_Ka) #' -#' Cl = TVCl*exp(ETA_Cl); -#' Vc = TVVc*exp(ETA_Vc); -#' Ka = TVKa*exp(ETA_Ka); +#' K20 <- Cl/Vc +#' Cc <- centr/Vc #' -#' K20 = Cl/Vc; -#' Cc = centr/Vc; -#' -#' d/dt(depot) = -Ka*depot; -#' d/dt(centr) = Ka*depot - K20*centr; -#' d/dt(AUC) = Cc; -#' }), -#' error_model = function(f,sigma) { -#' dv <- cbind(f,1) -#' g <- diag(dv%*%sigma%*%t(dv)) -#' return(sqrt(g)) -#' }, -#' theta = c(THETA_Cl=4.0, THETA_Vc=70.0, THETA_Ka=1.0), -#' omega = lotri::lotri({ETA_Cl + ETA_Vc + ETA_Ka ~ -#' c(0.2, -#' 0, 0.2, -#' 0, 0, 0.2)}), -#' sigma = lotri::lotri({prop + add ~ c(0.05,0.0,0.00)})) +#' d/dt(depot) = -Ka*depot +#' d/dt(centr) = Ka*depot - K20*centr +#' Cc ~ prop(prop.sd) +#' }) +#' } #' # df_patient01: event table for Patient01, following a 30 minutes intravenous #' # infusion #' df_patient01 <- data.frame(ID=1, @@ -399,37 +395,33 @@ poso_time_cmin <- function(dat=NULL,prior_model=NULL,tdm=FALSE, #' rxode2::setRxThreads(2L) # limit the number of threads #' #' # model -#' mod_run001 <- list( -#' ppk_model = rxode2::rxode({ -#' centr(0) = 0; -#' depot(0) = 0; +#' mod_run001 <- function() { +#' ini({ +#' THETA_Cl <- 4.0 +#' THETA_Vc <- 70.0 +#' THETA_Ka <- 1.0 +#' ETA_Cl ~ 0.2 +#' ETA_Vc ~ 0.2 +#' ETA_Ka ~ 0.2 +#' prop.sd <- sqrt(0.05) +#' }) +#' model({ +#' TVCl <- THETA_Cl +#' TVVc <- THETA_Vc +#' TVKa <- THETA_Ka #' -#' TVCl = THETA_Cl; -#' TVVc = THETA_Vc; -#' TVKa = THETA_Ka; +#' Cl <- TVCl*exp(ETA_Cl) +#' Vc <- TVVc*exp(ETA_Vc) +#' Ka <- TVKa*exp(ETA_Ka) #' -#' Cl = TVCl*exp(ETA_Cl); -#' Vc = TVVc*exp(ETA_Vc); -#' Ka = TVKa*exp(ETA_Ka); +#' K20 <- Cl/Vc +#' Cc <- centr/Vc #' -#' K20 = Cl/Vc; -#' Cc = centr/Vc; -#' -#' d/dt(depot) = -Ka*depot; -#' d/dt(centr) = Ka*depot - K20*centr; -#' d/dt(AUC) = Cc; -#' }), -#' error_model = function(f,sigma) { -#' dv <- cbind(f,1) -#' g <- diag(dv%*%sigma%*%t(dv)) -#' return(sqrt(g)) -#' }, -#' theta = c(THETA_Cl=4.0, THETA_Vc=70.0, THETA_Ka=1.0), -#' omega = lotri::lotri({ETA_Cl + ETA_Vc + ETA_Ka ~ -#' c(0.2, -#' 0, 0.2, -#' 0, 0, 0.2)}), -#' sigma = lotri::lotri({prop + add ~ c(0.05,0.0,0.00)})) +#' d/dt(depot) = -Ka*depot +#' d/dt(centr) = Ka*depot - K20*centr +#' Cc ~ prop(prop.sd) +#' }) +#' } #' # df_patient01: event table for Patient01, following a 30 minutes intravenous #' # infusion #' df_patient01 <- data.frame(ID=1, @@ -725,37 +717,33 @@ poso_dose_auc <- function(dat=NULL,prior_model=NULL,tdm=FALSE, #' rxode2::setRxThreads(2L) # limit the number of threads #' #' # model -#' mod_run001 <- list( -#' ppk_model = rxode2::rxode({ -#' centr(0) = 0; -#' depot(0) = 0; +#' mod_run001 <- function() { +#' ini({ +#' THETA_Cl <- 4.0 +#' THETA_Vc <- 70.0 +#' THETA_Ka <- 1.0 +#' ETA_Cl ~ 0.2 +#' ETA_Vc ~ 0.2 +#' ETA_Ka ~ 0.2 +#' prop.sd <- sqrt(0.05) +#' }) +#' model({ +#' TVCl <- THETA_Cl +#' TVVc <- THETA_Vc +#' TVKa <- THETA_Ka #' -#' TVCl = THETA_Cl; -#' TVVc = THETA_Vc; -#' TVKa = THETA_Ka; +#' Cl <- TVCl*exp(ETA_Cl) +#' Vc <- TVVc*exp(ETA_Vc) +#' Ka <- TVKa*exp(ETA_Ka) #' -#' Cl = TVCl*exp(ETA_Cl); -#' Vc = TVVc*exp(ETA_Vc); -#' Ka = TVKa*exp(ETA_Ka); +#' K20 <- Cl/Vc +#' Cc <- centr/Vc #' -#' K20 = Cl/Vc; -#' Cc = centr/Vc; -#' -#' d/dt(depot) = -Ka*depot; -#' d/dt(centr) = Ka*depot - K20*centr; -#' d/dt(AUC) = Cc; -#' }), -#' error_model = function(f,sigma) { -#' dv <- cbind(f,1) -#' g <- diag(dv%*%sigma%*%t(dv)) -#' return(sqrt(g)) -#' }, -#' theta = c(THETA_Cl=4.0, THETA_Vc=70.0, THETA_Ka=1.0), -#' omega = lotri::lotri({ETA_Cl + ETA_Vc + ETA_Ka ~ -#' c(0.2, -#' 0, 0.2, -#' 0, 0, 0.2)}), -#' sigma = lotri::lotri({prop + add ~ c(0.05,0.0,0.00)})) +#' d/dt(depot) = -Ka*depot +#' d/dt(centr) = Ka*depot - K20*centr +#' Cc ~ prop(prop.sd) +#' }) +#' } #' # df_patient01: event table for Patient01, following a 30 minutes intravenous #' # infusion #' df_patient01 <- data.frame(ID=1, @@ -1015,37 +1003,33 @@ poso_dose_conc <- function(dat=NULL,prior_model=NULL,tdm=FALSE, #' rxode2::setRxThreads(2L) # limit the number of threads #' #' # model -#' mod_run001 <- list( -#' ppk_model = rxode2::rxode({ -#' centr(0) = 0; -#' depot(0) = 0; +#' mod_run001 <- function() { +#' ini({ +#' THETA_Cl <- 4.0 +#' THETA_Vc <- 70.0 +#' THETA_Ka <- 1.0 +#' ETA_Cl ~ 0.2 +#' ETA_Vc ~ 0.2 +#' ETA_Ka ~ 0.2 +#' prop.sd <- sqrt(0.05) +#' }) +#' model({ +#' TVCl <- THETA_Cl +#' TVVc <- THETA_Vc +#' TVKa <- THETA_Ka #' -#' TVCl = THETA_Cl; -#' TVVc = THETA_Vc; -#' TVKa = THETA_Ka; +#' Cl <- TVCl*exp(ETA_Cl) +#' Vc <- TVVc*exp(ETA_Vc) +#' Ka <- TVKa*exp(ETA_Ka) #' -#' Cl = TVCl*exp(ETA_Cl); -#' Vc = TVVc*exp(ETA_Vc); -#' Ka = TVKa*exp(ETA_Ka); +#' K20 <- Cl/Vc +#' Cc <- centr/Vc #' -#' K20 = Cl/Vc; -#' Cc = centr/Vc; -#' -#' d/dt(depot) = -Ka*depot; -#' d/dt(centr) = Ka*depot - K20*centr; -#' d/dt(AUC) = Cc; -#' }), -#' error_model = function(f,sigma) { -#' dv <- cbind(f,1) -#' g <- diag(dv%*%sigma%*%t(dv)) -#' return(sqrt(g)) -#' }, -#' theta = c(THETA_Cl=4.0, THETA_Vc=70.0, THETA_Ka=1.0), -#' omega = lotri::lotri({ETA_Cl + ETA_Vc + ETA_Ka ~ -#' c(0.2, -#' 0, 0.2, -#' 0, 0, 0.2)}), -#' sigma = lotri::lotri({prop + add ~ c(0.05,0.0,0.00)})) +#' d/dt(depot) = -Ka*depot +#' d/dt(centr) = Ka*depot - K20*centr +#' Cc ~ prop(prop.sd) +#' }) +#' } #' # df_patient01: event table for Patient01, following a 30 minutes intravenous #' # infusion #' df_patient01 <- data.frame(ID=1, diff --git a/R/input_validation.R b/R/input_validation.R index f53e577..b07fdd2 100644 --- a/R/input_validation.R +++ b/R/input_validation.R @@ -1,5 +1,5 @@ #------------------------------------------------------------------------- -# posologyr: individual dose optimisation using population PK +# posologyr: individual dose optimization using population PK # Copyright (C) Cyril Leven # # This program is free software: you can redistribute it and/or modify diff --git a/R/iov.R b/R/iov.R index 3052133..ac85572 100644 --- a/R/iov.R +++ b/R/iov.R @@ -1,5 +1,5 @@ #------------------------------------------------------------------------- -# posologyr: individual dose optimisation using population PK +# posologyr: individual dose optimization using population PK # Copyright (C) Cyril Leven # # This program is free software: you can redistribute it and/or modify diff --git a/R/ofv.R b/R/ofv.R index 48bb549..35281c9 100644 --- a/R/ofv.R +++ b/R/ofv.R @@ -1,5 +1,5 @@ #------------------------------------------------------------------------- -# posologyr: individual dose optimisation using population PK +# posologyr: individual dose optimization using population PK # Copyright (C) Cyril Leven # # This program is free software: you can redistribute it and/or modify diff --git a/R/param_estim.R b/R/param_estim.R index 39873ce..93816be 100644 --- a/R/param_estim.R +++ b/R/param_estim.R @@ -1,5 +1,5 @@ #------------------------------------------------------------------------- -# posologyr: individual dose optimisation using population PK +# posologyr: individual dose optimization using population PK # Copyright (C) Cyril Leven # # This program is free software: you can redistribute it and/or modify @@ -50,37 +50,33 @@ #' #' @examples #' # model -#' mod_run001 <- list( -#' ppk_model = rxode2::rxode({ -#' centr(0) = 0; -#' depot(0) = 0; +#' mod_run001 <- function() { +#' ini({ +#' THETA_Cl <- 4.0 +#' THETA_Vc <- 70.0 +#' THETA_Ka <- 1.0 +#' ETA_Cl ~ 0.2 +#' ETA_Vc ~ 0.2 +#' ETA_Ka ~ 0.2 +#' prop.sd <- sqrt(0.05) +#' }) +#' model({ +#' TVCl <- THETA_Cl +#' TVVc <- THETA_Vc +#' TVKa <- THETA_Ka #' -#' TVCl = THETA_Cl; -#' TVVc = THETA_Vc; -#' TVKa = THETA_Ka; +#' Cl <- TVCl*exp(ETA_Cl) +#' Vc <- TVVc*exp(ETA_Vc) +#' Ka <- TVKa*exp(ETA_Ka) #' -#' Cl = TVCl*exp(ETA_Cl); -#' Vc = TVVc*exp(ETA_Vc); -#' Ka = TVKa*exp(ETA_Ka); +#' K20 <- Cl/Vc +#' Cc <- centr/Vc #' -#' K20 = Cl/Vc; -#' Cc = centr/Vc; -#' -#' d/dt(depot) = -Ka*depot; -#' d/dt(centr) = Ka*depot - K20*centr; -#' d/dt(AUC) = Cc; -#' }), -#' error_model = function(f,sigma) { -#' dv <- cbind(f,1) -#' g <- diag(dv%*%sigma%*%t(dv)) -#' return(sqrt(g)) -#' }, -#' theta = c(THETA_Cl=4.0, THETA_Vc=70.0, THETA_Ka=1.0), -#' omega = lotri::lotri({ETA_Cl + ETA_Vc + ETA_Ka ~ -#' c(0.2, -#' 0, 0.2, -#' 0, 0, 0.2)}), -#' sigma = lotri::lotri({prop + add ~ c(0.05,0.0,0.00)})) +#' d/dt(depot) = -Ka*depot +#' d/dt(centr) = Ka*depot - K20*centr +#' Cc ~ prop(prop.sd) +#' }) +#' } #' # df_patient01: event table for Patient01, following a 30 minutes intravenous #' # infusion #' df_patient01 <- data.frame(ID=1, @@ -175,37 +171,33 @@ poso_simu_pop <- function(dat=NULL,prior_model=NULL,n_simul=1000, #' rxode2::setRxThreads(1) # limit the number of threads #' #' # model -#' mod_run001 <- list( -#' ppk_model = rxode2::rxode({ -#' centr(0) = 0; -#' depot(0) = 0; -#' -#' TVCl = THETA_Cl; -#' TVVc = THETA_Vc; -#' TVKa = THETA_Ka; +#' mod_run001 <- function() { +#' ini({ +#' THETA_Cl <- 4.0 +#' THETA_Vc <- 70.0 +#' THETA_Ka <- 1.0 +#' ETA_Cl ~ 0.2 +#' ETA_Vc ~ 0.2 +#' ETA_Ka ~ 0.2 +#' prop.sd <- sqrt(0.05) +#' }) +#' model({ +#' TVCl <- THETA_Cl +#' TVVc <- THETA_Vc +#' TVKa <- THETA_Ka #' -#' Cl = TVCl*exp(ETA_Cl); -#' Vc = TVVc*exp(ETA_Vc); -#' Ka = TVKa*exp(ETA_Ka); +#' Cl <- TVCl*exp(ETA_Cl) +#' Vc <- TVVc*exp(ETA_Vc) +#' Ka <- TVKa*exp(ETA_Ka) #' -#' K20 = Cl/Vc; -#' Cc = centr/Vc; +#' K20 <- Cl/Vc +#' Cc <- centr/Vc #' -#' d/dt(depot) = -Ka*depot; -#' d/dt(centr) = Ka*depot - K20*centr; -#' d/dt(AUC) = Cc; -#' }), -#' error_model = function(f,sigma) { -#' dv <- cbind(f,1) -#' g <- diag(dv%*%sigma%*%t(dv)) -#' return(sqrt(g)) -#' }, -#' theta = c(THETA_Cl=4.0, THETA_Vc=70.0, THETA_Ka=1.0), -#' omega = lotri::lotri({ETA_Cl + ETA_Vc + ETA_Ka ~ -#' c(0.2, -#' 0, 0.2, -#' 0, 0, 0.2)}), -#' sigma = lotri::lotri({prop + add ~ c(0.05,0.0,0.00)})) +#' d/dt(depot) = -Ka*depot +#' d/dt(centr) = Ka*depot - K20*centr +#' Cc ~ prop(prop.sd) +#' }) +#' } #' # df_patient01: event table for Patient01, following a 30 minutes intravenous #' # infusion #' df_patient01 <- data.frame(ID=1, @@ -500,37 +492,33 @@ poso_estim_map <- function(dat=NULL,prior_model=NULL,return_model=TRUE, #' #' @examples #' # model -#' mod_run001 <- list( -#' ppk_model = rxode2::rxode({ -#' centr(0) = 0; -#' depot(0) = 0; +#' mod_run001 <- function() { +#' ini({ +#' THETA_Cl <- 4.0 +#' THETA_Vc <- 70.0 +#' THETA_Ka <- 1.0 +#' ETA_Cl ~ 0.2 +#' ETA_Vc ~ 0.2 +#' ETA_Ka ~ 0.2 +#' prop.sd <- sqrt(0.05) +#' }) +#' model({ +#' TVCl <- THETA_Cl +#' TVVc <- THETA_Vc +#' TVKa <- THETA_Ka #' -#' TVCl = THETA_Cl; -#' TVVc = THETA_Vc; -#' TVKa = THETA_Ka; +#' Cl <- TVCl*exp(ETA_Cl) +#' Vc <- TVVc*exp(ETA_Vc) +#' Ka <- TVKa*exp(ETA_Ka) #' -#' Cl = TVCl*exp(ETA_Cl); -#' Vc = TVVc*exp(ETA_Vc); -#' Ka = TVKa*exp(ETA_Ka); +#' K20 <- Cl/Vc +#' Cc <- centr/Vc #' -#' K20 = Cl/Vc; -#' Cc = centr/Vc; -#' -#' d/dt(depot) = -Ka*depot; -#' d/dt(centr) = Ka*depot - K20*centr; -#' d/dt(AUC) = Cc; -#' }), -#' error_model = function(f,sigma) { -#' dv <- cbind(f,1) -#' g <- diag(dv%*%sigma%*%t(dv)) -#' return(sqrt(g)) -#' }, -#' theta = c(THETA_Cl=4.0, THETA_Vc=70.0, THETA_Ka=1.0), -#' omega = lotri::lotri({ETA_Cl + ETA_Vc + ETA_Ka ~ -#' c(0.2, -#' 0, 0.2, -#' 0, 0, 0.2)}), -#' sigma = lotri::lotri({prop + add ~ c(0.05,0.0,0.00)})) +#' d/dt(depot) = -Ka*depot +#' d/dt(centr) = Ka*depot - K20*centr +#' Cc ~ prop(prop.sd) +#' }) +#' } #' # df_patient01: event table for Patient01, following a 30 minutes intravenous #' # infusion #' df_patient01 <- data.frame(ID=1, @@ -793,37 +781,33 @@ poso_estim_mcmc <- function(dat=NULL,prior_model=NULL,return_model=TRUE, #' @import data.table #' @examples #' # model -#' mod_run001 <- list( -#' ppk_model = rxode2::rxode({ -#' centr(0) = 0; -#' depot(0) = 0; -#' -#' TVCl = THETA_Cl; -#' TVVc = THETA_Vc; -#' TVKa = THETA_Ka; +#' mod_run001 <- function() { +#' ini({ +#' THETA_Cl <- 4.0 +#' THETA_Vc <- 70.0 +#' THETA_Ka <- 1.0 +#' ETA_Cl ~ 0.2 +#' ETA_Vc ~ 0.2 +#' ETA_Ka ~ 0.2 +#' prop.sd <- sqrt(0.05) +#' }) +#' model({ +#' TVCl <- THETA_Cl +#' TVVc <- THETA_Vc +#' TVKa <- THETA_Ka #' -#' Cl = TVCl*exp(ETA_Cl); -#' Vc = TVVc*exp(ETA_Vc); -#' Ka = TVKa*exp(ETA_Ka); +#' Cl <- TVCl*exp(ETA_Cl) +#' Vc <- TVVc*exp(ETA_Vc) +#' Ka <- TVKa*exp(ETA_Ka) #' -#' K20 = Cl/Vc; -#' Cc = centr/Vc; +#' K20 <- Cl/Vc +#' Cc <- centr/Vc #' -#' d/dt(depot) = -Ka*depot; -#' d/dt(centr) = Ka*depot - K20*centr; -#' d/dt(AUC) = Cc; -#' }), -#' error_model = function(f,sigma) { -#' dv <- cbind(f,1) -#' g <- diag(dv%*%sigma%*%t(dv)) -#' return(sqrt(g)) -#' }, -#' theta = c(THETA_Cl=4.0, THETA_Vc=70.0, THETA_Ka=1.0), -#' omega = lotri::lotri({ETA_Cl + ETA_Vc + ETA_Ka ~ -#' c(0.2, -#' 0, 0.2, -#' 0, 0, 0.2)}), -#' sigma = lotri::lotri({prop + add ~ c(0.05,0.0,0.00)})) +#' d/dt(depot) = -Ka*depot +#' d/dt(centr) = Ka*depot - K20*centr +#' Cc ~ prop(prop.sd) +#' }) +#' } #' # df_patient01: event table for Patient01, following a 30 minutes intravenous #' # infusion #' df_patient01 <- data.frame(ID=1, diff --git a/R/posologyr.R b/R/posologyr.R index f2b6566..244944b 100644 --- a/R/posologyr.R +++ b/R/posologyr.R @@ -1,5 +1,5 @@ #------------------------------------------------------------------------- -# posologyr: individual dose optimisation using population PK +# posologyr: individual dose optimization using population PK # Copyright (C) Cyril Leven # # This program is free software: you can redistribute it and/or modify diff --git a/R/residual_error.R b/R/residual_error.R index fced23a..774946a 100644 --- a/R/residual_error.R +++ b/R/residual_error.R @@ -1,5 +1,5 @@ #------------------------------------------------------------------------- -# posologyr: individual dose optimisation using population PK +# posologyr: individual dose optimization using population PK # Copyright (C) Cyril Leven # # This program is free software: you can redistribute it and/or modify @@ -31,7 +31,7 @@ #' \code{g <- sigma[1] + sigma[2]*f} #' #' @return Numeric vector, residual error -#' @export +#' @keywords internal error_model_comb1 <- function(f,sigma){ g <- sigma[1] + sigma[2]*f return(g) @@ -49,7 +49,7 @@ error_model_comb1 <- function(f,sigma){ #' \code{g <- sqrt(sigma[1]^2 + sigma[2]^2*f^2)} #' #' @return Numeric vector, residual error -#' @export +#' @keywords internal error_model_comb2 <- function(f,sigma){ g <- sqrt(sigma[1]^2 + sigma[2]^2*f^2) return(g) @@ -64,7 +64,7 @@ error_model_comb2 <- function(f,sigma){ #' residual error model #' #' @return Numeric vector, residual error -#' @export +#' @keywords internal error_model_mixednm <- function(f,sigma){ dv <- cbind(f,1) g <- diag(dv%*%sigma%*%t(dv)) diff --git a/R/utils.R b/R/utils.R index ff14aad..ea94beb 100644 --- a/R/utils.R +++ b/R/utils.R @@ -1,5 +1,5 @@ #------------------------------------------------------------------------- -# posologyr: individual dose optimisation using population PK +# posologyr: individual dose optimization using population PK # Copyright (C) Cyril Leven # # This program is free software: you can redistribute it and/or modify diff --git a/README.Rmd b/README.Rmd index 482fab2..2a38e2c 100644 --- a/README.Rmd +++ b/README.Rmd @@ -23,25 +23,21 @@ set.seed(1) ## Overview -Personalize drug regimens using individual pharmacokinetic and -pharmacokinetic-pharmacodynamic profiles. Using combining therapeutic drug -monitoring (TDM) data and a population model, `posologyr` provides accurate a -posteriori estimates and allows you to compute the optimal individualized dosing -regimen. +Personalize drug regimens using individual pharmacokinetic (PK) and pharmacokinetic-pharmacodynamic (PK-PD) profiles. By combining therapeutic drug monitoring (TDM) data with a population model, `posologyr` offers accurate posterior estimates and helps compute optimal individualized dosing regimens. -`posologyr` provides the following functions for dosage optimization: +Key dosage optimization functions in `posologyr` include: -+ `poso_dose_conc()` estimates the optimal dose to reach a target concentration at any given time -+ `poso_dose_auc()` estimates the optimal dose to reach a target area under the concentration/time curve (AUC) -+ `poso_time_cmin()` estimates the time needed to reach a target trough concentration (Cmin) -+ `poso_inter_cmin()` estimates the optimal inter-dose interval to reliably achieve a target Cmin between each administration ++ `poso_dose_conc()` estimates the optimal dose to achieve a target concentration at any given time ++ `poso_dose_auc()` estimates the dose needed to reach a target area under the concentration-time curve (AUC) ++ `poso_time_cmin()` estimates the time required to reach a target trough concentration (Cmin) ++ `poso_inter_cmin()` estimates the optimal dosing interval to consistently achieve a target Cmin -Individual pharmacokinetic (PK) profiles can be estimated with or without data from therapeutic drug monitoring (TDM): +Individual PK profiles can be estimated with or without TDM data: -+ `poso_estim_map()` computes the Maximum A Posteriori Bayesian Estimates (MAP-BE) of the individual PK parameters from the results of TDM -+ `poso_simu_pop()` samples from the the a priori distributions of PK parameters ++ `poso_estim_map()` computes Maximum A Posteriori Bayesian Estimates (MAP-BE) of individual PK parameters using TDM results ++ `poso_simu_pop()` samples from the the prior distributions of PK parameters -`posologyr` takes advantage of the simulation framework provided by the +`posologyr` leverages the simulation capabilities of the [rxode2](https://github.com/nlmixr2/rxode2) package. ## Installation diff --git a/README.md b/README.md index 882ed52..06e7307 100644 --- a/README.md +++ b/README.md @@ -12,33 +12,31 @@ status](https://www.r-pkg.org/badges/version/posologyr)](https://CRAN.R-project. ## Overview -Personalize drug regimens using individual pharmacokinetic and -pharmacokinetic-pharmacodynamic profiles. Using combining therapeutic -drug monitoring (TDM) data and a population model, `posologyr` provides -accurate a posteriori estimates and allows you to compute the optimal -individualized dosing regimen. +Personalize drug regimens using individual pharmacokinetic (PK) and +pharmacokinetic-pharmacodynamic (PK-PD) profiles. By combining +therapeutic drug monitoring (TDM) data with a population model, +`posologyr` offers accurate posterior estimates and helps compute +optimal individualized dosing regimens. -`posologyr` provides the following functions for dosage optimization: +Key dosage optimization functions in `posologyr` include: -- `poso_dose_conc()` estimates the optimal dose to reach a target +- `poso_dose_conc()` estimates the optimal dose to achieve a target concentration at any given time -- `poso_dose_auc()` estimates the optimal dose to reach a target area - under the concentration/time curve (AUC) -- `poso_time_cmin()` estimates the time needed to reach a target trough - concentration (Cmin) -- `poso_inter_cmin()` estimates the optimal inter-dose interval to - reliably achieve a target Cmin between each administration - -Individual pharmacokinetic (PK) profiles can be estimated with or -without data from therapeutic drug monitoring (TDM): - -- `poso_estim_map()` computes the Maximum A Posteriori Bayesian - Estimates (MAP-BE) of the individual PK parameters from the results of - TDM -- `poso_simu_pop()` samples from the the a priori distributions of PK +- `poso_dose_auc()` estimates the dose needed to reach a target area + under the concentration-time curve (AUC) +- `poso_time_cmin()` estimates the time required to reach a target + trough concentration (Cmin) +- `poso_inter_cmin()` estimates the optimal dosing interval to + consistently achieve a target Cmin + +Individual PK profiles can be estimated with or without TDM data: + +- `poso_estim_map()` computes Maximum A Posteriori Bayesian Estimates + (MAP-BE) of individual PK parameters using TDM results +- `poso_simu_pop()` samples from the the prior distributions of PK parameters -`posologyr` takes advantage of the simulation framework provided by the +`posologyr` leverages the simulation capabilities of the [rxode2](https://github.com/nlmixr2/rxode2) package. ## Installation @@ -134,7 +132,6 @@ library("posologyr") ``` r patient_map <- poso_estim_map(patient_data,mod_gentamicin_Xuan2003) -#> using C compiler: ‘gcc (Ubuntu 11.4.0-1ubuntu1~22.04) 11.4.0’ plot(patient_map$model,Cc) ``` @@ -155,7 +152,6 @@ estimated as follows: ``` r poso_time_cmin(patient_data,mod_gentamicin_Xuan2003,tdm=TRUE, target_cmin = 0.5) -#> using C compiler: ‘gcc (Ubuntu 11.4.0-1ubuntu1~22.04) 11.4.0’ #> $time #> [1] 44.9 #> diff --git a/_pkgdown.yml b/_pkgdown.yml index 36ad250..e8f0166 100644 --- a/_pkgdown.yml +++ b/_pkgdown.yml @@ -2,7 +2,7 @@ url: https://levenc.github.io/posologyr/ template: bootstrap: 5 reference: -- title: "Dose optimisation functions" +- title: "Dose optimization functions" - contents: - poso_dose_auc - poso_dose_conc @@ -15,7 +15,32 @@ reference: - poso_estim_mcmc - poso_estim_sir - poso_simu_pop -- title: "Error models" - desc: "Functions for user-defined posologyr models" -- contents: - - starts_with("error_model") +navbar: + left: + - text: Models & Data + icon: fas fa-book + menu: + - text: "Getting started" + - text: "Population models" + href: articles/population_models.html + - text: "Patient data" + href: articles/patient_data.html + - text: "--------------------------" + - text: "Advanced models" + - text: "Multiple endpoints models" + href: articles/multiple_endpoints.html + - text: "Classic posologyr models" + href: articles/classic_posologyr_models.html + - text: Dose selection + icon: fas fa-pills + menu: + - text: "A priori dose selection" + href: articles/a_priori_dosing.html + - text: "A posteriori dose selection" + href: articles/a_posteriori_dosing.html + - text: "AUC-based dose selection" + href: articles/auc_based_dosing.html + - text: "Route of administration" + href: articles/route_of_administration.html + - text: Changelog + href: news/index.html diff --git a/docs/404.html b/docs/404.html index ba759b8..2b97efb 100644 --- a/docs/404.html +++ b/docs/404.html @@ -36,16 +36,24 @@

A posteriori dose selection @@ -126,7 +136,7 @@

Patient record with TDM datavignette("patient_data_input") for more details regarding +vignette("patient_data_input") for more details regarding the patient record.

 df_patientA <- data.frame(ID=1,TIME=c(0,1,6),
@@ -183,10 +193,10 @@ 

#> [1] 2.487865 #> #> $indiv_param -#> THETA_Cl THETA_Vc THETA_Vp THETA_Q ETA_Cl ETA_Vc ETA_Vp ETA_Q -#> 3 4.3 15.9 21.4 12.1 0.4499479 0.2730561 0.7061648 -0.13884 -#> CLCREAT4H TBW PoverF -#> 3 50 62 169

+#> THETA_Cl THETA_Vc THETA_Vp THETA_Q add_sd prop_sd ETA_Cl ETA_Vc +#> 3 4.3 15.9 21.4 12.1 0.2 0.1 0.4499479 0.2730561 +#> ETA_Vp ETA_Q CLCREAT4H TBW PoverF +#> 3 0.7061648 -0.13884 50 62 169

The next dose (if needed) can be administered 33.9 hours following the first infusion.

@@ -214,10 +224,10 @@

Optimal dose selection a posteriori #> [1] 80 #> #> $indiv_param -#> THETA_Cl THETA_Vc THETA_Vp THETA_Q ETA_Cl ETA_Vc ETA_Vp ETA_Q -#> 3 4.3 15.9 21.4 12.1 0.4499608 0.2730596 0.7061496 -0.1388505 -#> CLCREAT4H TBW PoverF -#> 3 50 62 169 +#> THETA_Cl THETA_Vc THETA_Vp THETA_Q add_sd prop_sd ETA_Cl ETA_Vc +#> 3 4.3 15.9 21.4 12.1 0.2 0.1 0.4499608 0.2730596 +#> ETA_Vp ETA_Q CLCREAT4H TBW PoverF +#> 3 0.7061496 -0.1388505 50 62 169

The next dose should be 2450 mg.

@@ -242,10 +252,10 @@

Interdose interval selection #> [1] 2.500173 #> #> $indiv_param -#> THETA_Cl THETA_Vc THETA_Vp THETA_Q ETA_Cl ETA_Vc ETA_Vp ETA_Q -#> 1 4.3 15.9 21.4 12.1 0.449952 0.2730587 0.7061588 -0.1388432 -#> CLCREAT4H TBW PoverF -#> 1 50 62 169

+#> THETA_Cl THETA_Vc THETA_Vp THETA_Q add_sd prop_sd ETA_Cl ETA_Vc +#> 1 4.3 15.9 21.4 12.1 0.2 0.1 0.449952 0.2730587 +#> ETA_Vp ETA_Q CLCREAT4H TBW PoverF +#> 1 0.7061588 -0.1388432 50 62 169

The interval between doses should not be less than 38.6 hours to allow adequate elimination of amikacin between each infusion.

diff --git a/docs/articles/a_priori_dosing.html b/docs/articles/a_priori_dosing.html index e6ed840..76e0c16 100644 --- a/docs/articles/a_priori_dosing.html +++ b/docs/articles/a_priori_dosing.html @@ -35,16 +35,24 @@ +mod_amikacin_Burdet2015 <- function() { + ini({ + THETA_Cl=4.3 + THETA_Vc=15.9 + THETA_Vp=21.4 + THETA_Q=12.1 + ETA_Cl + ETA_Vc + ETA_Vp + ETA_Q ~ + c(0.1, + 0.01 , 0.05 , + 0.01 , 0.02 , 0.2 , + -0.06 , 0.004, 0.003, 0.08) + add_sd <- 0.2 + prop_sd <- 0.1 + }) + model({ + TVCl = THETA_Cl*(CLCREAT4H/82)^0.7 + TVVc = THETA_Vc*(TBW/78)^0.9*(PoverF/169)^0.4 + TVVp = THETA_Vp + TVQ = THETA_Q + Cl = TVCl*exp(ETA_Cl) + Vc = TVVc*exp(ETA_Vc) + Vp = TVVp*exp(ETA_Vp) + Q = TVQ *exp(ETA_Q) + ke = Cl/Vc + k12 = Q/Vc + k21 = Q/Vp + Cp = centr/Vc + d/dt(centr) = - ke*centr - k12*centr + k21*periph + d/dt(periph) = + k12*centr - k21*periph + + Cp ~ add(add_sd) + prop(prop_sd) + combined1() + }) + } +#> THETA_Cl THETA_Vc THETA_Vp THETA_Q add_sd prop_sd ETA_Cl ETA_Vc +#> 1 4.3 15.9 21.4 12.1 0.2 0.1 2.025724e-07 6.573817e-08 +#> ETA_Vp ETA_Q CLCREAT4H TBW PoverF +#> 1 2.011353e-07 -1.163665e-07 50 62 169

Time required to reach the target Cmin @@ -191,10 +201,10 @@

Time required to reach the targe #> [1] 2.49637 #> #> $indiv_param -#> THETA_Cl THETA_Vc THETA_Vp THETA_Q ETA_Cl ETA_Vc ETA_Vp -#> 1 4.3 15.9 21.4 12.1 -9.803026e-07 3.556777e-07 -3.567767e-07 -#> ETA_Q CLCREAT4H TBW PoverF -#> 1 9.847164e-07 50 62 169

+#> THETA_Cl THETA_Vc THETA_Vp THETA_Q add_sd prop_sd ETA_Cl ETA_Vc +#> 1 4.3 15.9 21.4 12.1 0.2 0.1 -9.803026e-07 3.556777e-07 +#> ETA_Vp ETA_Q CLCREAT4H TBW PoverF +#> 1 -3.567767e-07 9.847164e-07 50 62 169

Plotting the selected dosage diff --git a/docs/articles/auc_based_dosing.html b/docs/articles/auc_based_dosing.html index 92a965d..dac5c73 100644 --- a/docs/articles/auc_based_dosing.html +++ b/docs/articles/auc_based_dosing.html @@ -35,16 +35,24 @@ +mod_vancomycin_Goti2018 <- function() { + ini({ + THETA_Cl <- 4.5 + THETA_Vc <- 58.4 + THETA_Vp <- 38.4 + THETA_Q <- 6.5 + ETA_Cl ~ 0.147 + ETA_Vc ~ 0.510 + ETA_Vp ~ 0.282 + add.sd <- 3.4 + prop.sd <- 0.227 + }) + model({ + TVCl = THETA_Cl*(CLCREAT/120)^0.8*(0.7^DIAL); + TVVc = THETA_Vc*(WT/70) *(0.5^DIAL); + TVVp = THETA_Vp; + TVQ = THETA_Q; + Cl = TVCl*exp(ETA_Cl); + Vc = TVVc*exp(ETA_Vc); + Vp = TVVp*exp(ETA_Vp); + Q = TVQ; + ke = Cl/Vc; + k12 = Q/Vc; + k21 = Q/Vp; + Cc = centr/Vc; + d/dt(centr) = - ke*centr - k12*centr + k21*periph; + d/dt(periph) = + k12*centr - k21*periph; + d/dt(AUC) <- Cc + Cc ~ add(add.sd) + prop(prop.sd) + combined1() + }) + }

Discontinuous intravenous infusion @@ -125,7 +133,7 @@

Discontinuous intravenous infusionPatient record with TDM data

The dosage selection can be informed using the results of TDM. See -vignette("patient_data_input") for more details regarding +vignette("patient_data_input") for more details regarding the patient records.

 df_patientB <- data.frame(ID=1,TIME=c(0.0,13.0,24.2,48),
@@ -212,10 +220,10 @@ 

Optimal dose selection a posteriori #> [1] 400 #> #> $indiv_param -#> THETA_Cl THETA_Vc THETA_Vp THETA_Q ETA_Cl ETA_Vc ETA_Vp CLCREAT -#> 4 4.5 58.4 38.4 6.5 0.08208203 0.06122374 0.06285943 65 -#> WT DIAL -#> 4 70 0

+#> THETA_Cl THETA_Vc THETA_Vp THETA_Q add.sd prop.sd ETA_Cl ETA_Vc +#> 4 4.5 58.4 38.4 6.5 3.4 0.227 0.08208203 0.06122374 +#> ETA_Vp CLCREAT DIAL WT +#> 4 0.06285943 65 0 70

The optimal dose estimated for the next infusion is 1411 mg.

@@ -244,10 +252,10 @@

Optimal maintenance dos #> [1] 400 #> #> $indiv_param -#> THETA_Cl THETA_Vc THETA_Vp THETA_Q ETA_Cl ETA_Vc ETA_Vp CLCREAT WT -#> 1 4.5 58.4 38.4 6.5 0.08208199 0.06122337 0.0628591 65 70 -#> DIAL -#> 1 0

+#> THETA_Cl THETA_Vc THETA_Vp THETA_Q add.sd prop.sd ETA_Cl ETA_Vc +#> 1 4.5 58.4 38.4 6.5 3.4 0.227 0.08208199 0.06122337 +#> ETA_Vp CLCREAT DIAL WT +#> 1 0.0628591 65 0 70

The optimal maintenance dose is 1200 mg.

@@ -276,10 +284,10 @@

Continuous intravenous infusion#> [1] 400 #> #> $indiv_param -#> THETA_Cl THETA_Vc THETA_Vp THETA_Q ETA_Cl ETA_Vc ETA_Vp CLCREAT -#> 1 4.5 58.4 38.4 6.5 0.08208202 0.06122453 0.06285936 65 -#> WT DIAL -#> 1 70 0 +#> THETA_Cl THETA_Vc THETA_Vp THETA_Q add.sd prop.sd ETA_Cl ETA_Vc +#> 1 4.5 58.4 38.4 6.5 3.4 0.227 0.08208202 0.06122453 +#> ETA_Vp CLCREAT DIAL WT +#> 1 0.06285936 65 0 70

The optimal maintenance dose is also 1200 mg / 24 h for a continuous intravenous infusion.

diff --git a/docs/articles/classic_posologyr_models.html b/docs/articles/classic_posologyr_models.html new file mode 100644 index 0000000..7c772fa --- /dev/null +++ b/docs/articles/classic_posologyr_models.html @@ -0,0 +1,430 @@ + + + + + + + +Classic posologyr models • posologyr + + + + + + + + + + + + + +
Skip to contents + + +
+ + + + +
+
+ + + +
+

Introduction +

+

Originally, posologyr models were R lists; +posologyr still uses this format internally, but it’s often +more useful to use the rxode2 syntax, or even to import a +NONMEM model using the nonmem2rx package.

+

This article describes the structure of classical +posologyr models. It illustrates how to define them from +published population models.

+
+
+

Structure +

+

A posologyr model is a named R list of the following +items:

+
+
ppk_model
+
+A rxode2 model implementing the structural population model +with the individual model (i.e. the model of inter-individual +variability) and the covariates +
+
error_model
+
+A function of the residual error model, alternatively a named list of +functions for multiple endpoints model +vignette("multiple_endpoints") +
+
theta
+
+A named vector of the population estimates of the fixed effects +parameters (called THETAs, following NONMEM terminology) +
+
omega
+
+A named square variance-covariance matrix of the population parameters +inter-individual variability +
+
sigma
+
+The estimates of the parameters of the residual error model +
+
pi_matrix
+
+Optional. A named square variance-covariance matrix of the population +parameters inter-occasion variability +
+
covariates
+
+A character vector of the covariates of the model +
+
+
+
+

Definition of a prior model through an example +

+

The model in this example is a two-compartment ppk model of +vancomycin derived from a retrospective study with a cohort of over +1,800 patients (doi:10.1097/FTD.0000000000000490).

+
+

ppk_model +

+

A model defined in the rxode2 mini-language. +posologyr needs a structural model, defined with either +differential or algebraic equations, and an individual model. Depending +on model type, naming conventions are more or less strict:

+

Single endpoint model (e.g. most pharmacokinetic +models)

+
    +
  • The concentration in the central compartment must be named +Cc.
  • +
+

Multiple endpoints model (eg. PK-PD, +parent-metabolite, blood-urine…)

+
    +
  • The names of the endpoints are flexible, but they must be consistent +with the names of the error models and their parameters.
  • +
+

The differential function d/dt(AUC) = Cc; is needed for +the optimization function poso_dose_auc().

+
+ppk_model   = rxode2::rxode({
+    centr(0) = 0;
+    TVCl  = THETA_Cl*(CLCREAT/120)^0.8*(0.7^DIAL);
+    TVVc  = THETA_Vc*(WT/70)          *(0.5^DIAL);
+    TVVp  = THETA_Vp;
+    TVQ   = THETA_Q;
+    Cl    = TVCl*exp(ETA_Cl);
+    Vc    = TVVc*exp(ETA_Vc);
+    Vp    = TVVp*exp(ETA_Vp);
+    Q     = TVQ;
+    ke    = Cl/Vc;
+    k12   = Q/Vc;
+    k21   = Q/Vp;
+    Cc    = centr/Vc;
+    d/dt(centr)  = - ke*centr - k12*centr + k21*periph;
+    d/dt(periph) =            + k12*centr - k21*periph;
+    d/dt(AUC)    =   Cc;
+  })
+
+
+

error_model +

+

A function of the residual error model, taking two arguments: the +simulated concentrations, and a vector sigma of the +estimates of the parameters for the residual error model.

+
+error_model <- function(f,sigma){           #additive model if sigma[2] == 0
+  g <- sigma[1]^2 + (sigma[2]^2)*(f^2)      #proportional model if sigma[1] == 0
+  return(sqrt(g))
+}
+

For multiple endpoints models, error_model must be a +named list with a function for each endpoint +vignette("multiple_endpoints").

+
+error_model = list(
+    first_endpoint = function(f,sigma){
+      g <- sigma[1]^2 + (sigma[2]^2)*(f^2)
+      return(sqrt(g))
+    },
+    second_endpoint = function(f,sigma){
+      g <- sigma[1]^2 + (sigma[2]^2)*(f^2)
+      return(sqrt(g))
+    }
+  )
+

To obtain individual estimations for multiple endpoints, consistency +in the naming convention must be maintained across the following:

+
    +
  • The dataset (using the column DVID).
  • +
  • The residual error models (stored in a named list).
  • +
  • The standard deviation of the residual error models (stored in a +named list, see sigma).
  • +
+

As many residual error models as desired can be defined. Each model +defined in the named list error_models must have its counterpart in the +named list sigma, and the names must match those defined in +the DVID column of the dataset.

+
+
+

theta +

+

The estimations of the parameters for the fixed effects of the model +(THETA), in a named vector. The names must match the names used in +ppk_model.

+
+theta = c(THETA_Cl=4.5, THETA_Vc=58.4, THETA_Vp=38.4, THETA_Q=6.5)
+
+
+

omega +

+

The variance-covariance matrix of the random effects (ETA) for the +individual model. A symmetric matrix. The names must match the names +used in ppk_model. An easy way to define it is using +lotri::lotri().

+

The estimates of the variances of the random effects can be given +under different parameterizations depending on the authors.

+
    +
  • Standard deviation (SD): the square root of the variance, as +returned by Monolix
  • +
  • Coefficient of variation (CV): calculated as +sqrt(exp(SD^2)-1), the variance can be computed back with +log((CV^2)+1) +
  • +
  • Full covariance matrix: the easiest to reuse, but less common in the +literature
  • +
+

In the case of the vancomycin +model, the estimates of between subject variability (BSV) are given +as CV%. They must be converted to variances prior to their inclusion in +omega.

+ + + + + + + + + + + + + + + + + + + + + + + +
ParameterCV% (from the article)Variance = SD^2
BSV on CL39.80.147
BSV on Vc81.60.510
BSV on Vp57.10.282
+
+omega = lotri::lotri({ETA_Cl + ETA_Vc + ETA_Vp + ETA_Q ~
+                          c(0.147,
+                            0    ,  0.510 ,
+                            0    ,  0     ,   0.282,
+                            0    ,  0     ,   0    ,    0)})
+

The estimates of covariance (off-diagonal) are sometimes given as +coefficients of correlation between ETAs. The covariance between ETA_a +and ETA_b can be computed with the following product: +standard_deviation(ETA_a) * standard_deviation(ETA_b) * correlation(ETA_a and ETA_b).

+

In this example, all covariances are equal to zero.

+
+
+

sigma +

+

The estimates of the parameters for the residual error model on the +standard deviation scale, either in a vector:

+
+sigma       = c(additive_a = 3.4, proportional_b = 0.227)
+

in a matrix:

+
+sigma       = lotri::lotri({prop + add ~ c(0.227,0.0,3.4)})
+

or in a named list (for multiple endpoints):

+
+sigma       = list(
+    first_endpoint=c(additive_a = 0.144, proportional_b = 0.15),
+    second_endpoint=c(additive_a = 3.91, proportional_b = 0.0)
+    )
+

depending on the residual error model.

+
+
+

pi_matrix +

+

Optional: only needed for models with inter-occasion variability +(IOV). The variance-covariance matrix of the random effects (KAPPA) for +the IOV. As for the omega matrix, the names must match the +names used in ppk_model. An easy way to define it is using +lotri::lotri().

+
+pi_matrix = lotri::lotri({KAPPA_Cl + KAPPA_Vc ~
+      c(0.1934626,
+        0.00     ,  0.05783106)})
+
+
+

covariates +

+

The names of every covariate defined in ppk_model, in a +character vector.

+
+covariates  = c("CLCREAT","WT","DIAL")
+
+
+

Full model +

+

The posologyr model is the list of all these objects. +Note: this model does not include inter-occasion variability, so the +pi_matrix is omitted.

+
+mod_vancomyin_Goti2018 <- list(
+  ppk_model   = rxode2::rxode({
+     centr(0) = 0;
+    TVCl  = THETA_Cl*(CLCREAT/120)^0.8*(0.7^DIAL);
+    TVVc  = THETA_Vc*(WT/70)          *(0.5^DIAL);
+    TVVp  = THETA_Vp;
+    TVQ   = THETA_Q;
+    Cl    = TVCl*exp(ETA_Cl);
+    Vc    = TVVc*exp(ETA_Vc);
+    Vp    = TVVp*exp(ETA_Vp);
+    Q     = TVQ;
+    ke    = Cl/Vc;
+    k12   = Q/Vc;
+    k21   = Q/Vp;
+    Cc    = centr/Vc;
+    d/dt(centr)  = - ke*centr - k12*centr + k21*periph;
+    d/dt(periph) =            + k12*centr - k21*periph;
+    d/dt(AUC)    =   Cc;
+  }),
+  error_model = function(f,sigma){
+    g <- sigma[1] + sigma[2]*f
+    return(g)
+  },
+  theta = c(THETA_Cl=4.5, THETA_Vc=58.4, THETA_Vp=38.4,THETA_Q=6.5),
+  omega = lotri::lotri({ETA_Cl + ETA_Vc + ETA_Vp + ETA_Q ~
+                          c(0.147,
+                            0    ,  0.510 ,
+                            0    ,  0     ,   0.282,
+                            0    ,  0     ,   0    ,    0)}),
+  sigma       = c(additive_a = 3.4, proportional_b = 0.227),
+  covariates  = c("CLCREAT","WT","DIAL"))
+
+

Resulting R object +

+
+mod_vancomyin_Goti2018
+#> $ppk_model
+#> rxode2 NA model named rx_bce7176cfa18100af62e71ae38d3cd48 model ( ready). 
+#> $state: centr, periph, AUC
+#> $params: THETA_Cl, CLCREAT, DIAL, THETA_Vc, WT, THETA_Vp, THETA_Q, ETA_Cl, ETA_Vc, ETA_Vp
+#> $lhs: TVCl, TVVc, TVVp, TVQ, Cl, Vc, Vp, Q, ke, k12, k21, Cc
+#> 
+#> $error_model
+#> function(f,sigma){
+#>     g <- sigma[1] + sigma[2]*f
+#>     return(g)
+#>   }
+#> 
+#> $theta
+#> THETA_Cl THETA_Vc THETA_Vp  THETA_Q 
+#>      4.5     58.4     38.4      6.5 
+#> 
+#> $omega
+#>        ETA_Cl ETA_Vc ETA_Vp ETA_Q
+#> ETA_Cl  0.147   0.00  0.000     0
+#> ETA_Vc  0.000   0.51  0.000     0
+#> ETA_Vp  0.000   0.00  0.282     0
+#> ETA_Q   0.000   0.00  0.000     0
+#> 
+#> $sigma
+#>     additive_a proportional_b 
+#>          3.400          0.227 
+#> 
+#> $covariates
+#> [1] "CLCREAT" "WT"      "DIAL"
+
+
+
+
+
+ + + +
+ + + +
+
+ + + + + + + diff --git a/docs/articles/index.html b/docs/articles/index.html index 6344d4e..b57b6de 100644 --- a/docs/articles/index.html +++ b/docs/articles/index.html @@ -15,15 +15,21 @@

data: first subject from the warfarin dataset @@ -200,12 +196,14 @@

data: first subject from t #> $model #> ── Solved rxode2 object ── #> ── Parameters ($params): ── -#> THETA_ktr ETA_ktr THETA_ka ETA_ka THETA_cl ETA_cl -#> 0.10600000 -0.32052193 -0.08700000 -0.54227235 -2.03000000 0.79432182 -#> THETA_v ETA_v THETA_emax ETA_emax THETA_ec50 ETA_ec50 -#> 2.07000000 -0.02986447 3.40000000 0.02383273 0.00724000 -0.28133882 -#> THETA_kout ETA_kout THETA_e0 ETA_e0 -#> -2.90000000 -0.30872226 4.57000000 -0.08386652 +#> THETA_ktr THETA_ka THETA_cl THETA_v THETA_emax THETA_ec50 +#> 0.10600000 -0.08700000 -2.03000000 2.07000000 3.40000000 0.00724000 +#> THETA_kout THETA_e0 cp.sd cp.prop.sd pca.sd ETA_ktr +#> -2.90000000 4.57000000 0.14400000 0.15000000 3.91000000 -0.32052193 +#> ETA_ka ETA_cl ETA_v ETA_emax ETA_ec50 ETA_kout +#> -0.54227235 0.79432182 -0.02986447 0.02383273 -0.28133882 -0.30872226 +#> ETA_e0 +#> -0.08386652 #> ── Initial Conditions ($inits): ── #> depot gut center effect #> 0 0 0 0 diff --git a/docs/articles/patient_data.html b/docs/articles/patient_data.html new file mode 100644 index 0000000..88fac2b --- /dev/null +++ b/docs/articles/patient_data.html @@ -0,0 +1,290 @@ + + + + + + + +Patient data • posologyr + + + + + + + + + + + + + + Skip to contents + + +
+ + + + +
+
+ + + +
+

Introduction +

+

This describes the structure of patient records compatible with +posologyr.

+
+
+

Structure +

+

Data for input into posologyr is the same type of data +input for rxode2. As stated in the rxode2 +documentation (rxode2 datasets), it is also similar to data for NONMEM.

+

The patient dataset is a table of sequential event records, in which +each line is an event. A description of the different event types is +available in the rxode2 +documentation (rxode2 Event Types).

+

Below is a minimal working example:

+
+data.frame(ID=1,
+           TIME=c(0.0,3),
+           DV=c(NA,60.0),
+           AMT=c(1000,0),
+           EVID=c(101,0))
+#>   ID TIME DV  AMT EVID
+#> 1  1    0 NA 1000  101
+#> 2  1    3 60    0    0
+
+

Required fields and data +

+
+
TIME
+
+Dosing times, and sampling times of therapeutic drug monitoring (TDM). +The units depend on the specification of the population pharmacokinetics +(ppk) model. +
+
AMT
+
+Amount of drug administered. The units depend on the specification of +the ppk model. +
+
EVID
+
+Event type. Must be 0 for all observations (concentrations from TDM). +
+
DV
+
+For concentrations. Must be NA when EVID is not 0. +
+
Covariates
+
+Every covariate defined in the prior posologyr model. The +column names must match the covariate vector from the +ppk model. +
+
OCC
+
+Occasions. Required for models with inter-occasion variability. +
+
DVID
+
+Observation type. Required for models with multiple endpoints. +
+
CMT
+
+Name (or number) of the compartment where the dose is administered, see +vignette("route_of_administration"). +
+
+
+
+
+

Common use cases +

+
+

A priori dose adjustment +

+

Before dosing: the simplest patient record is a single line +dataframe, with individual patient covariates, and all other columns +(TIME, DV, AMT, EVID) set to zero.

+
+data.frame(ID=1,
+           TIME=0,
+           DV=0,
+           AMT=0,
+           EVID=0,
+           COVAR1=c("X"),
+           COVAR2=c("Y"))
+#>   ID TIME DV AMT EVID COVAR1 COVAR2
+#> 1  1    0  0   0    0      X      Y
+
+
+

Oral administration or IV bolus +

+

EVID = 1 for an instantaneous administration in the +first compartment defined in the ppk model: either the central +compartment for an IV bolus, or a depot compartment for an oral +administration.

+
+data.frame(ID=1,
+           TIME=c(0.0,3),
+           DV=c(NA,60.0),
+           AMT=c(1000,0),
+           EVID=c(1,0),
+           COVAR1=c("X"),
+           COVAR2=c("Y"))
+#>   ID TIME DV  AMT EVID COVAR1 COVAR2
+#> 1  1    0 NA 1000    1      X      Y
+#> 2  1    3 60    0    0      X      Y
+
+
+

Intermittent infusion +

+

EVID = 1 for a bolus infusion, administered in the first +compartment defined in the ppk model.

+

DUR defines its duration.

+

AMT is the amount administered over the duration +DUR.

+
+data.frame(ID=1,
+           TIME=c(0.0,1.0,14.0),
+           DV=c(NA,25.0,5.5),
+           AMT=c(1000,0,0),
+           DUR=c(0.5,NA,NA),
+           EVID=c(1,0,0),
+           COVAR1=c("X"),
+           COVAR2=c("Y"))
+#>   ID TIME   DV  AMT DUR EVID COVAR1 COVAR2
+#> 1  1    0   NA 1000 0.5    1      X      Y
+#> 2  1    1 25.0    0  NA    0      X      Y
+#> 3  1   14  5.5    0  NA    0      X      Y
+
+
+

Inter-occasion variability +

+

For a given occasion, the value of OCC must be repeated +for each row. OCC must be specified for all the rows in the +table.

+
+data.frame(ID=1,
+           TIME=c(0.0,1.0,14.0,24.0,25.0,36.0),
+           DV=c(NA,25.0,5.5,NA,30.0,6.0),
+           AMT=c(1000,0,0,1000,0,0),
+           DUR=c(0.5,NA,NA,0.5,NA,NA),
+           EVID=c(1,0,0,1,0,0),
+           OCC=c(1,1,1,2,2,2),
+           COVAR1=c("X"),
+           COVAR2=c("Y"))
+#>   ID TIME   DV  AMT DUR EVID OCC COVAR1 COVAR2
+#> 1  1    0   NA 1000 0.5    1   1      X      Y
+#> 2  1    1 25.0    0  NA    0   1      X      Y
+#> 3  1   14  5.5    0  NA    0   1      X      Y
+#> 4  1   24   NA 1000 0.5    1   2      X      Y
+#> 5  1   25 30.0    0  NA    0   2      X      Y
+#> 6  1   36  6.0    0  NA    0   2      X      Y
+
+
+

Multiple endpoints +

+

DVID is used to specify the type of each observation. +The values of DVID in the dataset must match the names of +the residual error models, see +vignette("multiple_endpoints").

+
+data.frame(ID=1,
+           TIME=c(0.0,1.0,14.0,24.0,25.0,36.0),
+           DV=c(NA,20.0,80,35.5,60.0,40.0),
+           AMT=c(1000,0,0,0,0,0),
+           EVID=c(1,0,0,0,0,0),
+           DVID=c("parent","parent","metabolite","parent","metabolite","metabolite"),
+           COVAR1=c("X"),
+           COVAR2=c("Y"))
+#>   ID TIME   DV  AMT EVID       DVID COVAR1 COVAR2
+#> 1  1    0   NA 1000    1     parent      X      Y
+#> 2  1    1 20.0    0    0     parent      X      Y
+#> 3  1   14 80.0    0    0 metabolite      X      Y
+#> 4  1   24 35.5    0    0     parent      X      Y
+#> 5  1   25 60.0    0    0 metabolite      X      Y
+#> 6  1   36 40.0    0    0 metabolite      X      Y
+
+
+
+
+ + + +
+ + + +
+
+ + + + + + + diff --git a/docs/articles/patient_data_input.html b/docs/articles/patient_data_input.html index 303897a..7cc9283 100644 --- a/docs/articles/patient_data_input.html +++ b/docs/articles/patient_data_input.html @@ -5,7 +5,7 @@ -Patient data input • posologyr +Patient records • posologyr @@ -16,7 +16,7 @@ - + Skip to contents @@ -39,13 +39,10 @@ @@ -67,7 +64,7 @@ diff --git a/docs/articles/population_models.html b/docs/articles/population_models.html new file mode 100644 index 0000000..fc725fa --- /dev/null +++ b/docs/articles/population_models.html @@ -0,0 +1,319 @@ + + + + + + + +Population models • posologyr + + + + + + + + + + + + + + Skip to contents + + +
+ + + + +
+
+ + + +
+

Introduction +

+

This describes the structure of prior population models compatible +with posologyr and illustrates how to define new models +from published population models.

+
+
+

General structure +

+

Most models can be written as a model function which can be parsed by +rxode2. The models are written in two block statements:

+
    +
  • +ini({}) defining parameter values
  • +
  • +model({}) for the ODE-based model specification.
  • +
+

For example, the gentamicin model of Xuan et al. 2003 (doi:10.1016/j.ijantimicag.2003.07.010) can be written +as:

+
+mod_gentamicin_Xuan2003 <- function() {
+  ini({
+    #Fixed effects: population estimates 
+    THETA_Cl  = 0.047
+    THETA_V   = 0.28
+    THETA_k12 = 0.092
+    THETA_k21 = 0.071
+    
+    #Random effects: inter-individual variability
+    ETA_Cl  ~ 0.084
+    ETA_V   ~ 0.003
+    ETA_k12 ~ 0.398
+    ETA_k21 ~ 0.342
+    
+    #Unexplained residual variability
+    add_sd  <- 0.230
+    prop_sd <- 0.237
+  })
+  model({
+    #Individual model and covariates
+    TVl   = THETA_Cl*ClCr
+    TVV   = THETA_V*WT
+    TVk12 = THETA_k12
+    TVk21 = THETA_k21
+    Cl    = TVl*exp(ETA_Cl)
+    V     = TVV*exp(ETA_V)
+    k12   = TVk12*exp(ETA_k12)
+    k21   = TVk21*exp(ETA_k21)
+    
+    #Structural model defined using ordinary differential equations (ODE)
+    ke    = Cl/V
+    Cp    = centr/V
+
+    d/dt(centr)  = - ke*centr - k12*centr + k21*periph
+    d/dt(periph) =            + k12*centr - k21*periph
+
+    #Model for unexplained residual variability
+    Cp ~ add(add_sd) + prop(prop_sd) + combined1()
+  })
+}
+

The rxode2 mini-language syntax is detailed in the rxode2 +documentation.

+
+
+

Individual model, random effects +

+

Inter-individual variability can also be defined as a symmetric +matrix to integrate the covariance between random effects. An easy way +to define it is using lotri::lotri().

+

For example, the amikacin model of Burdet et al. 2015 (doi:10.1007/s00228-014-1766-y) can be written as:

+
+mod_amikacin_Burdet2015 <- function() {
+    ini({
+      #Fixed effects: population estimates 
+      THETA_Cl=4.3
+      THETA_Vc=15.9
+      THETA_Vp=21.4
+      THETA_Q=12.1
+      
+      #Random effects: inter-individual variability
+      ETA_Cl + ETA_Vc + ETA_Vp + ETA_Q ~
+        c(0.1,
+          0.01     ,    0.05 ,
+          0.01     ,    0.02 ,   0.2  ,
+         -0.06     ,    0.004,   0.003,    0.08)
+          
+      #Unexplained residual variability
+      add_sd <- 0.2
+      prop_sd <- 0.1
+    })
+    model({
+      #Individual model and covariates
+      TVCl  = THETA_Cl*(CLCREAT4H/82)^0.7
+      TVVc  = THETA_Vc*(TBW/78)^0.9*(PoverF/169)^0.4
+      TVVp  = THETA_Vp
+      TVQ   = THETA_Q
+      Cl    = TVCl*exp(ETA_Cl)
+      Vc    = TVVc*exp(ETA_Vc)
+      Vp    = TVVp*exp(ETA_Vp)
+      Q     = TVQ *exp(ETA_Q)
+      
+      #Structural model defined using ordinary differential equations (ODE)
+      ke    = Cl/Vc
+      k12   = Q/Vc
+      k21   = Q/Vp
+      Cp    = centr/Vc      
+      
+      d/dt(centr)  = - ke*centr - k12*centr + k21*periph
+      d/dt(periph) =            + k12*centr - k21*periph
+
+      #Model for unexplained residual variability
+      Cp ~ add(add_sd) + prop(prop_sd) + combined1()
+    })
+  }
+

The estimates of the variances of the random effects can be given +under different parameterizations depending on the authors.

+
    +
  • Standard deviation (SD): the square root of the variance, as +returned by Monolix
  • +
  • Coefficient of variation (CV): calculated as +sqrt(exp(SD^2)-1), the variance can be computed back with +log((CV^2)+1) +
  • +
  • Full covariance matrix: the easiest to reuse, but less common in the +literature
  • +
+

The estimates of covariance (off diagonal) are sometimes given as +coefficients of correlation between ETAs. The covariance between ETA_a +and ETA_b can be computed with the following product: +standard_deviation(ETA_a) * standard_deviation(ETA_b) * correlation(ETA_a and ETA_b).

+
+
+

Bioavailability, lag-time +

+

Special model event changes including bioavailability +(f(depot)=1), and lag time (alag(depot)=0) can +be used in the model({}) block. For example, the +ganciclovir model of Caldès et al. 2009 (doi:10.1128/aac.00085-09) can be written as:

+
+mod_ganciclovir_Caldes2009 <- function() {
+  ini({
+    #Fixed effects: population estimates 
+    THETA_cl  <- 7.49
+    THETA_v1  <- 31.90
+    THETA_cld <- 10.20
+    THETA_v2  <- 32.0
+    THETA_ka  <- 0.895
+    THETA_baf <- 0.825
+      
+    #Random effects: inter-individual variability
+    ETA_cl ~ 0.107
+    ETA_v1 ~ 0.227
+    ETA_ka ~ 0.464
+    ETA_baf ~ 0.049
+    
+    #Unexplained residual variability
+    add.sd <- 0.465
+    prop.sd <- 0.143
+  })
+  model({
+    #Individual model and covariates
+    TVcl  = THETA_cl*(ClCr/57);
+    TVv1  = THETA_v1;
+    TVcld = THETA_cld;
+    TVv2  = THETA_v2;
+    TVka  = THETA_ka;
+    TVbaf = THETA_baf;
+    cl  = TVcl*exp(ETA_cl);
+    v1  = TVv1*exp(ETA_v1);
+    cld = TVcld;
+    v2  = TVv2;
+    ka  = TVka*exp(ETA_ka);
+    baf = TVbaf*exp(ETA_baf);
+
+    #Structural model defined using ordinary differential equations (ODE)
+    k10 = cl/v1;
+    k12 = cld / v1;
+    k21 = cld / v2;
+    Cc = centr/v1;
+
+    d/dt(depot)  = -ka*depot
+    d/dt(centr)  =  ka*depot - k10*centr - k12*centr + k21*periph;
+    d/dt(periph) =                         k12*centr - k21*periph;
+    d/dt(AUC)    = Cc;
+
+    #Special model event changes
+    f(depot)=baf;
+    alag(depot)=0.382;
+    
+    #Model for unexplained residual variability
+    Cc ~ add(add.sd) + prop(prop.sd) + combined1()
+  })
+}
+
+
+

Classic posologyr models +

+

Some models cannot be described by an rxode2 model +function alone. It is then possible to define a classic +posologyr model, see +vignette ("classic_posologyr_models"). Models falling in +this category are :

+
    +
  • models with inter-occasion variability (IOV), sometimes called +intra-individual variability
  • +
  • models with an unexplained residual error model other than additive, +proportional, or combined models
  • +
+
+
+
+ + + +
+ + + +
+
+ + + + + + + diff --git a/docs/articles/route_of_administration.html b/docs/articles/route_of_administration.html index 6891620..99670dd 100644 --- a/docs/articles/route_of_administration.html +++ b/docs/articles/route_of_administration.html @@ -35,16 +35,24 @@
 plot(map_patient$model,Cc)

Plot of the individual PK profile

@@ -187,7 +195,7 @@

Optimal dose for a new injection of IV ganciclovir by setting cmt_dose = "centr".

-poso_dose_auc(patient,mod_ganciclovir_Caldes_AAC2009,tdm=TRUE,
+poso_dose_auc(patient,mod_ganciclovir_Caldes_2009,tdm=TRUE,
               time_dose = 145,
               duration = 1,
               time_auc = 24,
@@ -215,7 +223,7 @@ 

Optimal dose for an administration of oral valganciclovir by setting cmt_dose = "depot".

-poso_dose_auc(patient,mod_ganciclovir_Caldes_AAC2009,tdm=TRUE,
+poso_dose_auc(patient,mod_ganciclovir_Caldes_2009,tdm=TRUE,
               time_dose = 145,
               time_auc = 24,
               target_auc = 50,
diff --git a/docs/authors.html b/docs/authors.html
index d1379a6..540980e 100644
--- a/docs/authors.html
+++ b/docs/authors.html
@@ -15,15 +15,21 @@
     
 
     
 patient_map <- poso_estim_map(patient_data,mod_gentamicin_Xuan2003)
-#> using C compiler: ‘gcc (Ubuntu 11.4.0-1ubuntu1~22.04) 11.4.0’
 plot(patient_map$model,Cc)

Plot of the individual profile

@@ -191,7 +198,6 @@

Dose optimization
 poso_time_cmin(patient_data,mod_gentamicin_Xuan2003,tdm=TRUE,
                target_cmin = 0.5)
-#> using C compiler: ‘gcc (Ubuntu 11.4.0-1ubuntu1~22.04) 11.4.0’
 #> $time
 #> [1] 44.9
 #> 
diff --git a/docs/news/index.html b/docs/news/index.html
index 370cce5..482c225 100644
--- a/docs/news/index.html
+++ b/docs/news/index.html
@@ -15,15 +15,21 @@
     
 
     
 

Bug fix

diff --git a/docs/pkgdown.yml b/docs/pkgdown.yml index d9a835d..79b549e 100644 --- a/docs/pkgdown.yml +++ b/docs/pkgdown.yml @@ -5,11 +5,12 @@ articles: a_posteriori_dosing: a_posteriori_dosing.html a_priori_dosing: a_priori_dosing.html auc_based_dosing: auc_based_dosing.html + classic_posologyr_models: classic_posologyr_models.html multiple_endpoints: multiple_endpoints.html - patient_data_input: patient_data_input.html - posologyr_user_defined_models: posologyr_user_defined_models.html + patient_data: patient_data.html + population_models: population_models.html route_of_administration: route_of_administration.html -last_built: 2024-07-28T21:27Z +last_built: 2024-08-27T07:11Z urls: reference: https://levenc.github.io/posologyr/reference article: https://levenc.github.io/posologyr/articles diff --git a/docs/reference/error_model_comb1.html b/docs/reference/error_model_comb1.html index bd3635d..ea5dff6 100644 --- a/docs/reference/error_model_comb1.html +++ b/docs/reference/error_model_comb1.html @@ -21,15 +21,21 @@