KURTOSIS

Applies to: ✅ Data 360 SQL ✅ Tableau Hyper API

Computes the unbiased excess kurtosis of input values. Excess kurtosis measures how heavy-tailed a distribution is relative to a normal distribution: positive values indicate heavier tails and more frequent outliers, negative values indicate lighter tails, and zero matches the normal distribution.

Syntax 

1kurtosis(<expression>)

Arguments 

Required 

  • <expression>: An expression of any numerical type.

Returns 

Returns a double precision value.

Returns NULL when fewer than four non-null input values are provided or when all non-null values are identical.

Considerations 

  • Returns excess kurtosis (Fisher definition): a normal distribution has KURTOSIS of 0, not 3. Add 3 to convert to raw (Pearson) kurtosis.
  • Uses an unbiased sample formula with finite-sample bias correction.
  • Ignores NULL inputs. Any NaN or infinite input propagates to a NaN result.

Examples 

Calculate Excess Kurtosis 

Find the excess kurtosis of response times.

1SELECT kurtosis(latency_ms) AS latency_kurtosis
2FROM request_logs;

Kurtosis by Group 

Compute kurtosis for each endpoint to flag those whose latency has the heaviest tails.

1SELECT endpoint, kurtosis(latency_ms) AS latency_kurtosis
2FROM request_logs
3GROUP BY endpoint
4ORDER BY latency_kurtosis DESC;

Summarize Distribution Shape 

Report skewness and kurtosis side by side to summarize the shape of daily returns per ticker.

1SELECT
2    ticker,
3    skewness_samp(return_pct) AS return_skew,
4    kurtosis(return_pct)      AS return_kurtosis
5FROM daily_returns
6GROUP BY ticker;

Related Documentation