View source: R/lme_model_table.R
lme_model_table | R Documentation |
Generate tables with multiple response, predictor, or two-way interaction variables (only lmer
models are supported).
You can pass multiple variables for one type of variable (either response, pred, or interaction) only.
If you want to pass multiple variables for multiple type of variable, try lmer_model_explore instead.
At the moment, multi-categorical variables are not supported as predictors or interactions (but control is fine). Binary variable should be numeric
instead of factor
This function also do not supports changing random slopes.
Please use other_parameters
if you want to add non-changing interaction term.
lme_model_table(
...,
data,
response_variable,
predictor_variable,
two_way_interaction_variable = NULL,
random_effect,
control_variable = NULL,
other_parameters = NULL,
marginal_alpha = 0.1,
return_result = FALSE,
verbose = TRUE,
show_p = FALSE
)
... |
additional parameters pass to lmerTest::lmer() |
data |
|
response_variable |
response variable. Support |
predictor_variable |
predictor variable. Support |
two_way_interaction_variable |
Two-way interaction variable. Each two-way interaction variable will interact with the predictor variable. Support |
random_effect |
The random-effects terms in the format of |
control_variable |
control variables. Support |
other_parameters |
catch call for all other parameters that need to be entered (e.g., non-changing interaction terms). Have to be |
marginal_alpha |
the set marginal_alpha level for marginally significant (denoted by |
return_result |
It set to |
verbose |
default is |
show_p |
show the p-value in parenthesis |
data.frame
# If you want all varibles to be changing, try lmer_model_explore.
# For more examples, see ?lm_model_table.
# Changing interaction terms with a non-changing response variable
lme_model_table(data = popular,
response_variable = popular,
predictor_variable = texp,
two_way_interaction_variable = c(extrav,sex),
random_effect = '(1 | class)')
# A non-changing interaction term with changing response variables
lme_model_table(data = popular,
response_variable = c(popular,sex),
predictor_variable = texp,
other_parameters = 'texp*extrav',
random_effect = '(1 | class)')
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.