center.predictors: Transform all data by subtracting a constant, either the...

Description Usage Examples

Description

Transform all data by subtracting a constant, either the mean, median value, or a submitted constant.

The input may be a vector or a matrix. If a matrix, each column is centered on its mean (median), or by passing a vector of constants. Note that setting by=0 amounts to no change.

Usage

1
center.predictors(x, by = "mean")

Examples

1
2
3
4
## Not run: 
center.predictors(x=c(1,4,7,0),by='median')
center.predictors(x=c(1,4,7,0),by=2)
## End(Not run)

forestgeo/ctfs documentation built on May 3, 2019, 6:44 p.m.