|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.jaitools.numeric.AbstractProcessor
org.jaitools.numeric.ApproxMedianProcessor
public class ApproxMedianProcessor
Processor for the approximate median Statistic.APPROX_MEDIAN.
Calculation of an exact median is only possible by storing all sample
values. For very large data streams, this processor will calculate an
approximate median using the remedian estimator:
PJ Rousseeuw and GW Bassett (1990) The remedian: a robust averaging method for large data sets. Journal of the American Statistical Society 85:97-104
The remedian estimator performs badly with non-stationary data, e.g. a data stream that is monotonically increasing will result in an over-estimate. If possible (which it probably isn't), it will help to de-trend or randomly order the data prior to streaming it.
Statistic,
StreamingSampleStats| Field Summary |
|---|
| Fields inherited from class org.jaitools.numeric.AbstractProcessor |
|---|
numAccepted, numNaN, numNoData, numOffered |
| Constructor Summary | |
|---|---|
ApproxMedianProcessor()
Default constructor. |
|
| Method Summary | |
|---|---|
Double |
get(Statistic stat)
Gets the value of the statistic calculated by this processor. |
Collection<Statistic> |
getSupported()
Gets the Statistics supported by this processor. |
protected boolean |
update(Double sample)
Processes a sample value. |
| Methods inherited from class org.jaitools.numeric.AbstractProcessor |
|---|
addNoDataRange, addNoDataValue, addRange, addRange, get, getNoDataRanges, getNumAccepted, getNumNaN, getNumNoData, getNumOffered, getRanges, getRangesType, isAccepted, offer, setRangesType |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public ApproxMedianProcessor()
| Method Detail |
|---|
public Collection<Statistic> getSupported()
Statistics supported by this processor.
Statisticsprotected boolean update(Double sample)
update in class AbstractProcessorsample - the sample value
true if the sample is accepted;
false otherwisepublic Double get(Statistic stat)
stat - the specified statistic
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||