Skip to main content

Module common

Module common 

Source
Expand description

Shared helpers for the statistics module.

All numeric conversions are explicit: float64 never silently enters exact arithmetic, non-finite values are rejected, and non-numeric array entries are reported with their path.

Enums§

Moment
An exact or approximate statistical moment.
Series
A numeric series in the representation chosen for the calculation.

Functions§

all_modes
Descriptive statistics support all three numeric modes.
allocation_ratio_param
alpha_param
any_number_schema
array_schema
array_value
assumptions_value
A text array of method assumptions, shared by the inference records.
bool_schema
bool_value
classify_series
Convert an input array to either exact rationals or float64 values.
collect_numbers
compensated_sum
Neumaier compensated summation.
confidence_param
covariance_exact
covariance_f64
Two-pass centered covariance with compensated summation.
covariance_moment
ensure_finite
example_args
extreme_number
field
float64_schema
float_array
float_number
float_value
float_vector
Collect a non-empty numeric array as float64 values, preserving the path of the offending entry in any conversion error.
inferential_modes
Distributions and inference always produce float64 results and therefore require auto or scientific mode.
insufficient
integer_schema
integer_value
mean_exact
mean_f64
mean_moment
median_number
mode_numbers
All tied modes and their counts, sorted ascending.
non_negative_u64
number_field
number_to_f64
number_value
optional_f64_param
optional_field
parse_choice
parse_value
power_param
probability_param
quantile_number
R-7 style quantiles with alternative order-statistic conventions.
rational_sqrt_exact
Exact square root of a non-negative rational, when one exists.
rational_to_number
rational_value
record
record_schema
scalar_f64
sided_param
stddev_moment
Convert a variance moment to a standard deviation under the mode rules: an exact perfect square stays exact, otherwise exact mode is rejected, auto mode returns a decimal approximation, and scientific mode returns float64.
text
text_schema
variance_exact
variance_f64
Welford’s online algorithm for the sample variance.
variance_moment