add_cov_to_formula: Add a Covariate to a Formula

View source: R/BMisc.R

add_cov_to_formulaR Documentation

Add a Covariate to a Formula

Description

add_cov_to_formula adds some covariates to a formula; covs should be a list of variable names

Usage

add_cov_to_formula(covs, formula)

Arguments

covs

should be a list of variable names

formula

which formula to add covariates to

Value

formula

Examples

ff <- y ~ x
add_cov_to_formula(list("w", "z"), ff)

ff <- ~x
add_cov_to_formula("z", ff)


bcallaway11/BMisc documentation built on Feb. 4, 2025, 10:43 p.m.