On this page

Winsorization

How Statsig applies winsorization to cap extreme metric values, reducing variance and stabilizing experiment results against influential outliers.

Winsorization is a technique for reducing noise in experiment results caused by outliers.

Winsorization measures the percentile Px of a metric and sets all values above Px to Px.

Statsig computes the Px value using all non-zero and non-null unit-level values of the metric. Statsig aggregates metrics from rows or events and uses the Px'th unit's value as the threshold to adjust other units' values.

At Statsig, the default percentile for winsorization is 99.9%. This default reduces the influence of extreme outliers caused by factors such as logging errors or bad actors.

Statsig applies winsorization to sum, event count, mean, ratio, and funnel metrics, including imported metrics. Winsorization doesn't apply to Participation or User Accounting metrics.

Metric capping

Metric capping is a technique for handling outliers. You can define maximum values for a metric for any unit types configured for that metric. Statsig automatically adjusts any value that exceeds the cap downward to match the cap.

For example, if purchases greater than $10,000 per day shouldn't skew analysis, Statsig adjusts any transaction exceeding that threshold downward to $10,000. Statsig supports capped metrics for Event Count and Aggregation (sum) metric types.

Was this helpful?