View source: R/addformulabars.R
AddFormulaBars | R Documentation |
Replaces factor variables in a formula
with their
representation as a random effect (e.g. a factor f
becomes
(1|f)
) as done for formulas in e.g. the lme4
and
nlme
packages.
AddFormulaBars(frml, data)
frml |
A model |
data |
A |
A formula with one factor f
and one continuous
variable c
in the formula
dat <- data.frame(c1 = 1:3, c2 = rnorm(3), f1 = factor(1:3), f2 = ordered(1:3))
frml <- ~c1+c2+f1+f2
AddFormulaBars(frml, dat)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.