toformula | R Documentation |
take a name for a y variable and a vector of names for x variables and turn them into a formula
toformula(yname, xnames)
yname |
the name of the y variable |
xnames |
vector of names for x variables |
a formula
toformula("yvar", c("x1", "x2"))
## should return yvar ~ 1
toformula("yvar", rhs.vars(~1))
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.