View source: R/simulate_nlme_one.R
simulate_nlme_one | R Documentation |
nlme
This function is based on predict.nlme
function
simulate_nlme_one(
object,
psim = 1,
level = Q,
asList = FALSE,
na.action = na.fail,
naPattern = NULL,
data = NULL,
...
)
object |
object of class |
psim |
parameter simulation level, 0: for fitted values, 1: for simulation from fixed parameters (assuming a fixed vcov matrix), 2: for simulation considering the residual error (sigma), this returns data which will appear similar to the observed values. Currently, working on psim = 3, which will simulate a new set of random effects. This can be useful when computing prediction intervals at the subject-level. |
level |
level at which simulations are performed. See |
asList |
optional logical value. See |
na.action |
missing value action. See |
naPattern |
missing value pattern. See |
data |
the data argument is needed when using this function inside user defined functions. |
... |
additional arguments to be passed (possible to pass newdata this way) |
It uses function mvrnorm
to generate new values for the coefficients
of the model using the Variance-Covariance matrix vcov
This function should return a vector with the same dimensions as the original data, unless newdata is provided.
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.