Interface PSquarePercentile.PSquareMarkers
-
- Enclosing class:
- PSquarePercentile
protected static interface PSquarePercentile.PSquareMarkers
An interface that encapsulates abstractions of the P-square algorithm markers as is explained in the original works. This interface is exposed with protected access to help in testability.
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description PSquarePercentile.PSquareMarkers
copySelf()
A deep copy function to clone the current instance.double
estimate(int index)
An Estimate of the percentile value of a given Markerdouble
getPercentileValue()
Returns Percentile value computed thus far.double
height(int markerIndex)
Returns the marker height (or percentile) of a given marker index.double
processDataPoint(double inputDataPoint)
Process a data point by moving the marker heights based on estimator.
-
-
-
Method Detail
-
getPercentileValue
double getPercentileValue()
Returns Percentile value computed thus far.- Returns:
- percentile
-
copySelf
PSquarePercentile.PSquareMarkers copySelf()
A deep copy function to clone the current instance.- Returns:
- deep copy of this instance
-
height
double height(int markerIndex)
Returns the marker height (or percentile) of a given marker index.- Parameters:
markerIndex
- is the index of marker in the marker array- Returns:
- percentile value of the marker index passed
- Throws:
MathIllegalArgumentException
- in case the index is not within [1-5]
-
processDataPoint
double processDataPoint(double inputDataPoint)
Process a data point by moving the marker heights based on estimator.- Parameters:
inputDataPoint
- is the data point passed- Returns:
- computed percentile
-
estimate
double estimate(int index)
An Estimate of the percentile value of a given Marker- Parameters:
index
- the marker's index in the array of markers- Returns:
- percentile estimate
- Throws:
MathIllegalArgumentException
- in case if index is not within [1-5]
-
-