Centering (Grand-Mean Centering)
Performs a grand-mean centering of data.
center(x, ...) ## S3 method for class 'numeric' center(x, weights = NULL, robust = FALSE, verbose = TRUE, ...) ## S3 method for class 'data.frame' center( x, select = NULL, exclude = NULL, weights = NULL, robust = FALSE, force = FALSE, append = FALSE, suffix = "_c", verbose = TRUE, ... )
x |
A data frame, a (numeric or character) vector or a factor. |
... |
Currently not used. |
weights |
Can be
|
robust |
Logical, if |
verbose |
Toggle warnings and messages. |
select |
Character vector of column names. If |
exclude |
Character vector of column names to be excluded from selection. |
force |
Logical, if |
append |
Logical, if |
suffix |
Character value, will be appended to variable (column) names of
|
The centered variables.
If centering within-clusters (instead of grand-mean centering)
is required, see demean
.
data(iris) head(iris$Sepal.Width) head(center(iris$Sepal.Width)) head(center(iris)) head(center(iris, force = TRUE))
Please choose more modern alternatives, such as Google Chrome or Mozilla Firefox.