linear_model: Linear Model

Description Usage Arguments Value Examples

View source: R/linear_model.R

Description

Implement a linear regression based on given model and data.

Usage

1

Arguments

formula

A symbolic description of the model to be fitted. This should be a formula class argument.

data

Specification of a dataframe that contains the variables in the model.

contrasts

A list of contrasts.

Value

A list of component that imitates the output of lm() function. Including estimated coefficients for predictors specified in the formula.

Examples

1
2
data(iris)
linear_model(Sepal.Length ~ ., iris, contrasts)

Zebedial/bis557 documentation built on Dec. 21, 2020, 2:16 a.m.