public class StandardScalerModel extends Object implements VectorTransformer
param: std column standard deviation values param: mean column mean values param: withStd whether to scale the data to have unit standard deviation param: withMean whether to center the data before scaling
Constructor and Description |
---|
StandardScalerModel(Vector std) |
StandardScalerModel(Vector std,
Vector mean) |
StandardScalerModel(Vector std,
Vector mean,
boolean withStd,
boolean withMean) |
Modifier and Type | Method and Description |
---|---|
Vector |
mean() |
StandardScalerModel |
setWithMean(boolean withMean)
:: DeveloperApi ::
|
StandardScalerModel |
setWithStd(boolean withStd)
:: DeveloperApi ::
|
Vector |
std() |
Vector |
transform(Vector vector)
Applies standardization transformation on a vector.
|
boolean |
withMean() |
boolean |
withStd() |
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
transform, transform
public StandardScalerModel(Vector std, Vector mean, boolean withStd, boolean withMean)
public StandardScalerModel(Vector std, Vector mean)
std
- (undocumented)mean
- (undocumented)public StandardScalerModel(Vector std)
public Vector std()
public Vector mean()
public boolean withStd()
public boolean withMean()
public StandardScalerModel setWithMean(boolean withMean)
withMean
- (undocumented)public StandardScalerModel setWithStd(boolean withStd)
withStd
- (undocumented)public Vector transform(Vector vector)
transform
in interface VectorTransformer
vector
- Vector to be standardized.0.0
for the column with zero std.