R/bootstrap_lme4.R
, R/bootstrap_nlme.R
, R/generics.R
parametric_bootstrap.Rd
Generate parametric bootstrap replicates of a statistic for a nested linear mixed-effects model.
# S3 method for merMod parametric_bootstrap(model, .f, B, .refit = TRUE) # S3 method for lme parametric_bootstrap(model, .f, B, .refit = TRUE) parametric_bootstrap(model, .f, B, .refit = TRUE)
model | The model object you wish to bootstrap. |
---|---|
.f | A function returning the statistic(s) of interest. |
B | The number of bootstrap resamples. |
.refit | a logical value indicating whether the model should be refit to
the bootstrap resample, or if the simulated bootstrap resample should be
returned. Defaults to |
The returned value is an object of class "lmeresamp".
The parametric bootstrap simulates bootstrap samples from the estimated distribution functions. That is, error terms and random effects are simulated from their estimated normal distributions and are combined into bootstrap samples via the fitted model equation.
Chambers, R. and Chandra, H. (2013) A random effect block bootstrap for clustered data. Journal of Computational and Graphical Statistics, 22, 452--470.
Van der Leeden, R., Meijer, E. and Busing F. M. (2008) Resampling multilevel models. In J. de Leeuw and E. Meijer, editors, Handbook of Multilevel Analysis, pages 401--433. New York: Springer.
Examples are given in bootstrap
parametric_bootstrap
, resid_bootstrap
,
case_bootstrap
, reb_bootstrap
,
wild_bootstrap
for more details on a specific bootstrap.
bootMer
in the lme4 package for an
implementation of (semi-)parametric bootstrap for mixed models.