pebaystats package

single pass descriptive statistics

class pebaystats.dstats(max_moment=4, width=1)

implement Pebay’s reduced complexity descriptive statistical moments

Members
max_moment:largest statistical moment to be calculated
n:number of elements over which moments are calculated
moments:list of current moment values

Todo

add covariance calculations

Todo

extend to general formulas

add(value)

add a (single) new value to each column of the aggregated statistics

Arguments
value:row of data values to aggregate (numpy array of values)

Todo

handle multiple rows for value

aggregate(rhs)

aggregate two dstat objects to hold the combined statistical moment values

Arguments
rhs:the other accumulator object to be aggregated

Todo

determine why the kurtosis accuracy is degraded for aggregation.

remove(value)

remove a value from the aggregated statistics

Arguments
value:value to be removed from the accumulated data elements

Todo

implement remove method

statistics(calculateDeviation=False)

generate and return the descriptive statistic of the current aggregation

Arguments
calculateDeviation:
 boolean flag that indicates whether the second result is the variance or deviation
return:array of the descriptive statistics (numpy array of float64)