Unlimited learning, half price | 50% off

Last chance! 50% off unlimited learning

Sale ends in


emdi (version 2.0.1)

step: Step function

Description

This generic function selects a model by different criteria in a stepwise algorithm.

Usage

step(object, scope, criteria, direction, trace, steps, ...)

# S3 method for default step(object, ...)

Arguments

object

an object of type "emdi","model" or a lm object.

scope

formula or a list including two formulas (lower and upper) specifying the models considered in the step function. Defaults to NULL.

criteria

a character string describing the model selection criterion.

direction

a character string describing the direction of stepwise algorithm. Directions that can be chosen are "both", "backward" or "forward". Defaults to "both". If no scope argument is provided, the default is "backward".

trace

if TRUE, information about the single steps is provided during the stepwise procedure. Defaults to TRUE.

steps

a number determining the maximum number of steps. Defaults to 1000.

...

arguments to be passed to or from other methods.

Value

The return of step depends on the class of its argument. The documentation of particular methods gives detailed information about the return of that method.

Details

The default method of the generic function step applies the step function for lm models of the stats package. Please refer to the documentation of the step function of the stats package for details.

See Also

step