Become an expert in R — Interactive courses, Cheat Sheets, certificates and more!
Get Started for Free

contr.earth.response

Please ignore


Description

Contrasts function for factors in the earth response. For internal use by earth.

Usage

contr.earth.response(x, base, contrasts)

Arguments

x

a factor

base

unused

contrasts

unused

Value

Returns a diagonal matrix. An example for a 3 level factor with levels A, B, and C:

A B C
    A 1 0 0
    B 0 1 0
    C 0 0 1

Note

Earth uses this function internally. You shouldn't need it. It is made publicly available only because it seems that is necessary for model.matrix.

See Also


earth

Multivariate Adaptive Regression Splines

v5.3.0
GPL-3
Authors
Stephen Milborrow. Derived from mda:mars by Trevor Hastie and Rob Tibshirani. Uses Alan Miller's Fortran utilities with Thomas Lumley's leaps wrapper.
Initial release

We don't support your browser anymore

Please choose more modern alternatives, such as Google Chrome or Mozilla Firefox.