This function is used to create a NpdeData object, representing a longitudinal data structure, and fill it with data from a dataframe or a file on disk
npdeData(name.data,header=TRUE,sep="",na.strings=c(".","NA"),name.group,
name.predictor, name.response, name.covariates,name.cens,name.miss,name.ipred,
units=list(x="",y="",covariates=c()), detect=TRUE,verbose=FALSE)
an object of class NpdeData
name of the file containing the observed data, or a dataframe containing the observed data
boolean indicating whether the file has a header (a header is mandatory if detect is TRUE)
field separator (for files on disk)
strings to be considered as indicating NA
name/number of the column in the observed data containing the patient ID (if missing and detect is TRUE, columns named id, subject or sujet (regardless of case) will be assumed to contain this information)
name/number of the column in the observed data containing the independent variable X (if missing and detect is TRUE, columns named xobs, time, dose, x, temps, tim (regardless of case) will be assumed to contain this information)
name/number of the column in the observed data containing the dependent variable Y (if missing and detect is TRUE, columns named yobs, response, resp, conc, concentration (regardless of case) will be assumed to contain this information)
name/number of the column(s) containing covariate information (optional)
name/number of the column containing information about censored data (cens) (if missing and detect is TRUE, column with a name containing cens (regardless of case) will be assumed to contain this information)
name/number of the column containing information about missing data (MDV) (if missing and detect is TRUE, column called mdv or miss (regardless of case) will be assumed to contain this information)
name/number of the column(s) with individual predictions (ipred) (if missing and detect is TRUE, column with a name containing ipred (regardless of case) will be assumed to contain this information)
a list with components x, y and cov (optional), specifying the units respectively for the predictor (x), the response (y), and the covariates (a vector of length equal to the number of covariates). Units will default to (-) if not given.
a boolean controlling whether automatic recognition of columns in the dataset is on, defaults to TRUE
whether to print warning messages, defaults to FALSE (set to TRUE to check how data is being handled)
Emmanuelle Comets <emmanuelle.comets@bichat.inserm.fr>
K. Brendel, E. Comets, C. Laffont, C. Laveille, and F. Mentré. Metrics for external model evaluation with an application to the population pharmacokinetics of gliclazide. Pharmaceutical Research, 23:2036--49, 2006.
npde
, autonpde
data(theopp)
x<-npdeData(theopp) # Automatic detection
print(x)
x<-npdeData(theopp,name.group="ID",name.predictor="Time",name.response="Conc",
name.covariates=c("Wt"),units=list(x="hr",y="mg/L",covariates="kg")) # Explicit
print(x)
Run the code above in your browser using DataLab