
public class OutlierLinearScaling extends Object implements OutlierScalingFunction
| Modifier and Type | Class and Description | 
|---|---|
static class  | 
OutlierLinearScaling.Parameterizer
Parameterization class. 
 | 
| Modifier and Type | Field and Description | 
|---|---|
(package private) double | 
factor
Scaling factor to use (1/ max - min) 
 | 
protected Double | 
max
Field storing the Maximum value 
 | 
static OptionID | 
MAX_ID
Parameter to specify the maximum value. 
 | 
static OptionID | 
MEAN_ID
Flag to use the mean as minimum for scaling. 
 | 
protected Double | 
min
Field storing the Minimum to use 
 | 
static OptionID | 
MIN_ID
Parameter to specify a fixed minimum to use. 
 | 
(package private) boolean | 
nozeros
Ignore zero values 
 | 
static OptionID | 
NOZEROS_ID
Flag to use ignore zeros when computing the min and max. 
 | 
(package private) boolean | 
usemean
Use the mean for scaling 
 | 
| Constructor and Description | 
|---|
OutlierLinearScaling()
Constructor. 
 | 
OutlierLinearScaling(Double min,
                    Double max,
                    boolean usemean,
                    boolean nozeros)
Constructor. 
 | 
| Modifier and Type | Method and Description | 
|---|---|
double | 
getMax()
Get maximum resulting value. 
 | 
double | 
getMin()
Get minimum resulting value. 
 | 
double | 
getScaled(double value)
Transform a given value using the scaling function. 
 | 
void | 
prepare(OutlierResult or)
Prepare is called once for each data set, before getScaled() will be
 called. 
 | 
public static final OptionID MIN_ID
 Key: -linearscale.min
 
public static final OptionID MAX_ID
 Key: -linearscale.max
 
public static final OptionID MEAN_ID
 Key: -linearscale.usemean
 
public static final OptionID NOZEROS_ID
 Key: -linearscale.ignorezero
 
protected Double min
protected Double max
double factor
boolean usemean
boolean nozeros
public double getScaled(double value)
ScalingFunctiongetScaled in interface ScalingFunctionvalue - Original valuepublic void prepare(OutlierResult or)
OutlierScalingFunctionprepare in interface OutlierScalingFunctionor - Outlier result to usepublic double getMin()
ScalingFunctionDouble.NaN or
 Double.NEGATIVE_INFINITY.getMin in interface ScalingFunctionpublic double getMax()
ScalingFunctionDouble.NaN or
 Double.POSITIVE_INFINITY.getMax in interface ScalingFunction