public class AffineTransformModel extends Object implements EstimatableModel<Point2d,Point2d>, MatrixTransformProvider
| Modifier and Type | Field and Description |
|---|---|
protected Predicate<AffineTransformModel> |
modelCheck |
protected Jama.Matrix |
transform |
| Constructor and Description |
|---|
AffineTransformModel()
Create an
AffineTransformModel |
AffineTransformModel(Predicate<AffineTransformModel> mc)
Create an
AffineTransformModel. |
| Modifier and Type | Method and Description |
|---|---|
AffineTransformModel |
clone()
Clone the model
|
boolean |
estimate(List<? extends IndependentPair<Point2d,Point2d>> data)
Estimates the model from the observations in the list of data.
|
Jama.Matrix |
getTransform() |
int |
numItemsToEstimate() |
Point2d |
predict(Point2d p)
Uses the model to predict dependent data from an independent value.
|
String |
toString() |
protected Predicate<AffineTransformModel> modelCheck
protected Jama.Matrix transform
public AffineTransformModel()
AffineTransformModelpublic AffineTransformModel(Predicate<AffineTransformModel> mc)
AffineTransformModel. The given Predicate is
used by the estimate(List) method to test whether the estimated
affine transform is sensible.mc - the test function for sensible affine transformspublic AffineTransformModel clone()
EstimatableModelpublic Jama.Matrix getTransform()
getTransform in interface MatrixTransformProviderpublic boolean estimate(List<? extends IndependentPair<Point2d,Point2d>> data)
EstimatableModelEstimatableModel.numItemsToEstimate() pairs of dependent
and independent data. It may contain more, in which case the estimate
method may choose to make use of this data for validation, or obtaining a
better model by a least squares method for example.estimate in interface EstimatableModel<Point2d,Point2d>data - Data with which to estimate the modelEstimatableModel.numItemsToEstimate()public Point2d predict(Point2d p)
Modelpublic int numItemsToEstimate()
numItemsToEstimate in interface EstimatableModel<Point2d,Point2d>