constructFormula | R Documentation |
Construct a formula string
constructFormula(dep = NULL, terms)
dep |
the name of the dependent variable |
terms |
list of character vectors making up the terms |
a string representation of the formula
constructFormula(terms=list('a', 'b', c('a', 'b')))
# a+b+a:b
constructFormula('f', list('a', 'b', c('a', 'b')))
# "f~a+b+a:b"
constructFormula('with spaces', list('a', 'b', c('a', 'b')))
'`with spaces`~a+b+a:b'
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.