center_data {sparsediscrim}R Documentation

Centers the observations in a matrix by their respective class sample means

Description

Centers the observations in a matrix by their respective class sample means

Usage

center_data(x, y)

Arguments

x

Matrix or data frame containing the training data. The rows are the sample observations, and the columns are the features. Only complete data are retained.

y

vector of class labels for each training observation

Value

matrix with observations centered by its corresponding class sample mean


[Package sparsediscrim version 0.3.0 Index]