Matrix stats aggregation
/ Matrix_stats, / AggregationMatrix stats aggregation #
A multi-value metrics aggregation computing counts, means, variances, skewness, kurtosis and the correlation matrix across several numeric fields at once.
How it works #
The aggregation works row-wise: a document contributes a row only if it
has a value for every listed field (a missing map can fill gaps
per field). Documents with any gap are dropped entirely — the reported
count is the number of complete rows, and every statistic uses the
same rows. At least two rows are required; below that the result is
empty.