substituting_formula: A substituting formula helps clarify a formula where the...

Description Usage Arguments Details Value Functions Examples

View source: R/substituting_formula.R

Description

A substituting formula helps clarify a formula where the parameters are more simply described in separate formulae.

Usage

1
2
3

Arguments

x

The base formula

...

Supporting formula of the form x1~x2+x3*x4...

substitutions

A list of supporting formula.

Details

Formula are substituted in order. Substitutions may not have the same left hand side.

Value

A substituting_formula object which may be coerced into a single formula with an as.formula() method or printed as a list of formulae.

Functions

Examples

1
2
foo <- substituting_formula(y~x1+x2, x1~x3*x4, x2~x5/x6+x7)
as.formula(foo)

Example output

y ~ x3 * x4 + (x5/x6 + x7)

formulops documentation built on Feb. 22, 2020, 5:07 p.m.