View source: R/stats_helpers.R
bootstrap_all | R Documentation |
Parametric bootstrapping
bootstrap_all(
nboot,
mod,
R2_type,
all_comb,
partition,
data_mod,
allow_neg_r2,
parallel,
expct,
overdisp_name
)
nboot |
Number of parametric bootstrap iterations for confidence interval estimation
(defaults to NULL, i.e. no bootstrapping). Larger numbers of bootstraps give a better
asymptotic CI, but may be time-consuming. Bootstrapping can be switched on by setting
|
mod |
merMod object, lme4 fit |
R2_type |
"marginal" or "conditional" R2. With "marginal", the variance explained by fixed effects is calculated. With "conditional", the variance explained by both fixed and random effects is calculated. |
all_comb |
list of predictor combinations |
partition |
TRUE or FALSE |
data_mod |
Data for model |
allow_neg_r2 |
Calculating part R2 involves fitting two models, one with and one without the predictor of interest. In cases where the predictor has little association with the response, the resulting part R2 value can become negative. By default we set negative values to 0, but by setting this parameter to TRUE, R2 values can become negative. |
parallel |
If TRUE, computation uses |
expct |
A string specifying the method for estimating the expectation in Poisson models with log link and in Binomial models with logit link (in all other cases the argument is ignored). The only valid terms are 'meanobs', 'latent', 'none' (and 'liability for binary and proportion data). With the default 'meanobs', the expectation is estimated as the mean of the observations in the sample. With 'latent', the expectation is estimated from estimates of the intercept and variances on the link scale. While this is a preferred solution, it is susceptible to the distribution of fixed effect covariates and gives appropriate results typically only when all covariances are centered to zero. With 'liability' estimates follow formulae as presented in Nakagawa & Schielzeth (2010). With 'none', R2 is calculated without distribution specific variance in the denominator. |
overdisp_name |
Name of overdispersion term |
Bootstrap samples for all statistics, plus associated warnings
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.