Read perpetrator information from file or text string
read_perpetrators.Rd
The input source can either be a file name as string or a text connection. This can be used to read the compound data from a string.
Value
A perpetrator object if only one compound in the input source, or list of perpetrator objects.
Details
The following fields are expected in the input (in this order):
'name' The compound name as character.
'parameter' The parameter as character.
'value' The respective value as character.
'source' Optional source information as character.
The following parameters are expected:
'oral' A Boolean (i.e.,
TRUE
orFALSE
) to indicate whether the drug is subject to first-pass effects.'mw' The molar weight in g/mol as numeric.
'dose' The clinically administered dose in mg as numeric.
'imaxss' The (total) \(C_{max}\) in ng/ml after administration of the clinical dose.
'fu' The free unbound) fraction of the drug in plasma.
'fumic' The free (unbound) fraction in microsomal preparations.
'rb' The blood-to-plasma concentration ratio.
'fa' The fraction absorbed of the drug.
'fg' The fraction of the administered dose escaping gut metabolism.
'ka' The absorption rate constant in 1/min.
'solubility' The aqueous solubility of the compound in mg/l.
Lines starting with '#' are considered comments and are not evaluated.
Note that multiple compounds, e.g., the parent and metabolites may be included in the perpetrator file. The below is an example of a valid compound file:
# PARENT
# compound, param, value, source
examplinib, oral, TRUE,
examplinib, mw, 492.6,
examplinib, dose, 450, clinical dose
examplinib, imaxss, 3530, study 001
examplinib, fu, 0.023, study 002
examplinib, fumic, 1, default
examplinib, rb, 1, study 003
examplinib, fa, 0.81, study 003
examplinib, fg, 1, default
examplinib, ka, 0.00267, unknown
# METABOLITE
# compound, param, value, source
M1, oral, FALSE,
M1, mw, 506.56,
M1, dose, NA,
M1, imaxss, 1038, study 001
M1, fu, 0.012, study 002
M1, fumic, 1, default
M1, rb, 1, study 002
M1, fa, NA,
M1, fg, NA,
M1, ka, NA,
Examples
read_perpetrators(textConnection(examplinib_compounds_string))
#> $M1
#> ----- DDI perpetrator object -----
#> name M1
#> oral FALSE
#> mw 506.56
#> dose NA
#> imaxss 1038 study 001
#> fu 0.012 study 002
#> fumic 1 default
#> rb 1 study 002
#> fa NA
#> fg NA
#> ka NA
#> solubility Inf default
#> $examplinib
#> ----- DDI perpetrator object -----
#> name examplinib
#> oral TRUE
#> mw 492.6
#> dose 450 clinical dose
#> imaxss 3530 study 001
#> fu 0.023 study 002
#> fumic 1 default
#> rb 1 study 003
#> fa 0.81 study 003
#> fg 1 default
#> ka 0.00267 unknown
#> solubility Inf default