Class PinotFourthMoment
- java.lang.Object
-
- org.apache.commons.math.stat.descriptive.AbstractUnivariateStatistic
-
- org.apache.commons.math.stat.descriptive.AbstractStorelessUnivariateStatistic
-
- org.apache.commons.math.stat.descriptive.moment.FirstMoment
-
- org.apache.commons.math.stat.descriptive.moment.SecondMoment
-
- org.apache.commons.math.stat.descriptive.moment.ThirdMoment
-
- org.apache.commons.math.stat.descriptive.moment.FourthMoment
-
- org.apache.pinot.segment.local.customobject.PinotFourthMoment
-
- All Implemented Interfaces:
Serializable,Comparable<PinotFourthMoment>,org.apache.commons.math.stat.descriptive.StorelessUnivariateStatistic,org.apache.commons.math.stat.descriptive.UnivariateStatistic
public class PinotFourthMoment extends org.apache.commons.math.stat.descriptive.moment.FourthMoment implements Comparable<PinotFourthMoment>
AComparableimplementation of the Fourth Statistical Moment that uses the apache commons algorithm for computing it in one pass. It additionally supports serialization and deserialization methods, which is helpful for combining moments across servers.The commons implementation does not support parallel-computation, support for which is added in the
combine(PinotFourthMoment)method inspired by Presto's implementation.Also See: Presto's Implementation
- See Also:
- Serialized Form
-
-
Constructor Summary
Constructors Constructor Description PinotFourthMoment()
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description voidcombine(long bN, double bM1, double bM2, double bM3, double bM4)voidcombine(PinotFourthMoment other)intcompareTo(PinotFourthMoment o)static PinotFourthMomentfromBytes(byte[] bytes)static PinotFourthMomentfromBytes(ByteBuffer buff)doublekurtosis()byte[]serialize()doubleskew()-
Methods inherited from class org.apache.commons.math.stat.descriptive.moment.FourthMoment
clear, copy, copy, getResult, increment
-
Methods inherited from class org.apache.commons.math.stat.descriptive.AbstractStorelessUnivariateStatistic
equals, evaluate, evaluate, hashCode, incrementAll, incrementAll
-
-
-
-
Method Detail
-
combine
public void combine(PinotFourthMoment other)
-
combine
public void combine(long bN, double bM1, double bM2, double bM3, double bM4)
-
skew
public double skew()
-
kurtosis
public double kurtosis()
-
serialize
public byte[] serialize()
-
fromBytes
public static PinotFourthMoment fromBytes(byte[] bytes)
-
fromBytes
public static PinotFourthMoment fromBytes(ByteBuffer buff)
-
compareTo
public int compareTo(PinotFourthMoment o)
- Specified by:
compareToin interfaceComparable<PinotFourthMoment>
-
-