dislib.preprocessing

Classes

class dislib.preprocessing.classes.StandardScaler(arity=50)[source]

Bases: object

Standardize features by removing the mean and scaling to unit variance

Centering and scaling happen independently on each feature by computing the relevant statistics on the samples in the training set. Mean and standard deviation are then stored to be used on later data using the transform method.

Parameters:

arity (int, optional (default=50)) – Arity of the reduction phase carried out to compute the mean and variance of the input dataset.

Variables:
  • mean (ndarray, shape (n_features,)) – The mean value for each feature in the training set.
  • var (ndarray, shape (n_features,)) – The variance for each feature in the training set.
fit(dataset)[source]

Compute the mean and std to be used for later scaling.

Parameters:dataset (Dataset)
fit_transform(dataset)[source]

Fit to data, then transform it.

Parameters:dataset (Dataset)
mean_
transform(dataset)[source]

Standarize data.

Parameters:dataset (Dataset)
var_