model_matrix | R Documentation |
This is a thin wrapper around stats::model.matrix()
which
returns a tibble. Use it to determine how your modelling formula is
translated into a matrix, an thence into an equation.
model_matrix(data, formula, ...)
data |
A data frame |
formula |
A modelling formula |
... |
Other arguments passed onto |
A tibble.
model_matrix(mtcars, mpg ~ cyl)
model_matrix(iris, Sepal.Length ~ Species)
model_matrix(iris, Sepal.Length ~ Species - 1)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.