res: Compare data and model prediction by computing residuals

Description Usage Arguments Value

View source: R/data.R

Description

Compare data and model prediction by computing residuals

Usage

1
res(data, out, err = NULL)

Arguments

data

data.frame with name (factor), time (numeric), value (numeric) and sigma (numeric)

out

output of ode(), optionally augmented with attributes "deriv" (output of ode() for the sensitivity equations) and "parameters" (character vector of parameter names, a subsest of those contained in the sensitivity equations). If "deriv" is given, also "parameters" needs to be given.

err

output of the error model function

Value

data.frame with the original data augmented by columns "prediction" ( numeric, the model prediction), "residual" (numeric, difference between prediction and data value), "weighted.residual" (numeric, residual devided by sigma). If "deriv" was given, the returned data.frame has an attribute "deriv" (data.frame with the derivatives of the residuals with respect to the parameters).


dMod documentation built on Jan. 27, 2021, 1:07 a.m.