This function attempts to return, or compute, p-values of a model's parameters. The nature of the p-values is different depending on the model:
Mixed models (lme4): By default, p-values are based on Wald-test approximations (see p_value_wald
). For lmerMod
objects, if method = "kenward"
, p-values are based on Kenward-Roger approximations, i.e. p_value_kenward
is called.
p_value(model, ...)# S3 method for lmerMod
p_value(model, method = "wald", ...)
# S3 method for glmmTMB
p_value(model, component = c("all", "conditional",
"zi", "zero_inflated"), ...)
# S3 method for MixMod
p_value(model, component = c("all", "conditional", "zi",
"zero_inflated"), ...)
p_value_robust(model, vcov_estimation = "HC", vcov_type = c("HC3",
"const", "HC", "HC0", "HC1", "HC2", "HC4", "HC4m", "HC5"),
vcov_args = NULL, ...)
A statistical model.
Arguments passed down to standard_error_robust()
when confidence intervals or p-values based on robust standard errors should be computed.
Should all parameters, parameters for the conditional model,
or for the zero-inflated part of the model be returned? Applies to models
with zero-inflated component. component
may be one of "conditional"
,
"zi"
, "zero-inflated"
or "all"
(default). May be abbreviated.
Character vector, specifying the estimation type for the
robust covariance matrix estimation (see vcovHC
for
details).
List of named vectors, used as additional arguments that
are passed down to the sandwich-function specified in vcov_estimation
.
The p-values.
# NOT RUN {
model <- lme4::lmer(Petal.Length ~ Sepal.Length + (1 | Species), data = iris)
p_value(model)
# }
Run the code above in your browser using DataLab