Learn R Programming

insight (version 0.18.6)

find_parameters.emmGrid: Find model parameters from estimated marginal means objects

Description

Returns the parameter names from a model.

Usage

# S3 method for emmGrid
find_parameters(x, flatten = FALSE, merge_parameters = FALSE, ...)

Value

A list of parameter names. For simple models, only one list-element, conditional, is returned.

Arguments

x

A fitted model.

flatten

Logical, if TRUE, the values are returned as character vector, not as list. Duplicated values are removed.

merge_parameters

Logical, if TRUE and x has multiple columns for parameter names (like emmGrid objects may have), these are merged into a single parameter column, with parameters names and values as values.

...

Currently not used.

Examples

Run this code
data(mtcars)
model <- lm(mpg ~ wt * factor(cyl), data = mtcars)
if (require("emmeans", quietly = TRUE)) {
  emm <- emmeans(model, c("wt", "cyl"))
  find_parameters(emm)
}

Run the code above in your browser using DataLab