public class InverseOfTransform extends Object implements DataTransform
InvertibleTransform
as a regular transform. This allows one to apply
inverses after the fact in a simple matter like:
DataSet x = //some data set;
InvertibleTransform transform = //some transform;
x.applyTransform(transform);//apply the original transform
//reverse the transform, getting back to where we started
x.applyTransform(new InverseOfTransform(transform));
Constructor and Description |
---|
InverseOfTransform(InverseOfTransform toClone)
Copy constructor
|
InverseOfTransform(InvertibleTransform transform)
Creates a new transform that uses the
transform of the given transform |
Modifier and Type | Method and Description |
---|---|
InverseOfTransform |
clone() |
void |
fit(DataSet data)
Fits this transform to the given dataset.
|
DataPoint |
transform(DataPoint dp)
Returns a new data point that is a transformation of the original data
point.
|
public InverseOfTransform(InvertibleTransform transform)
transform
of the given transformtransform
- the transform to use the inverse function ofpublic InverseOfTransform(InverseOfTransform toClone)
toClone
- the object to copypublic void fit(DataSet data)
DataTransform
FailedToFitException
exception may be
thrown.fit
in interface DataTransform
data
- the dataset to fir this transform topublic DataPoint transform(DataPoint dp)
DataTransform
transform
in interface DataTransform
dp
- the data point to apply a transformation topublic InverseOfTransform clone()
clone
in interface DataTransform
clone
in class Object
Copyright © 2017. All rights reserved.