Learn R Programming

speccurvieR (version 0.4.2)

paste_factory: Paste together controls and independent variable

Description

`paste_factory()` constructs the right hand side of the regression as a a string i.e. "x + control1 + control2".

Usage

paste_factory(controls, x)

Value

A string concatenating independent and control variables separated by '+'.

Arguments

controls

A vector of strings containing control variable names.

x

A string containing the independent variable name.

Examples

Run this code
paste_factory(controls = c("control1", "control2"),
              x = "independentVariable");

Run the code above in your browser using DataLab