This help topic is for R version 0.64.2. For the current version of R, try https://stat.ethz.ch/R-manual/R-patched/library/base/html/model.frame.html
model.frame {base}R Documentation

Extracting the “Environment” of a Model Formula

Description

model.frame (generic function) and its methods return a data.frame with the variables from formula.

Usage

model.frame(formula, data, na.action, ...)
model.frame.default(formula, data=sys.frame(sys.parent()),
                    na.action = na.fail, ...)

Methods for
	lm	glm	aovlist

Arguments

formula

a model formula

data

data.frame or environment where the objects in formula are.

na.action

how NAs are treated.

...

further arguments such as.......

Value

A data.frame containing the variables used in formula.

See Also

model.matrix for the “design matrix”.

Examples

data(cars)
data.class(model.frame(dist ~ speed, data = cars))

[Package base version 0.64.2 ]