# Distribution Moments

Computes the shape of a rolling return distribution (mean, variance, standard deviation, skewness, and kurtosis) over 252 bars of log returns, plotting a chosen moment (skewness by default) while a dashboard reports all of them with tail reads. Alerts fire when skewness crosses ±0.5 or raw kurtosis clears 3, flagging asymmetry and fat tails for quantitative traders.

- Indicator in the LuxAlgo Library, by LuxAlgo, published May 19, 2026.
- Access: free.
- Concepts: [Distribution Moments](https://www.luxalgo.com/library/concept/distribution-moments/) (primary)
- Open on Vela: https://vela.luxalgo.com/chart?pineScriptCodeId=n357teg2h6jahf10gju9rp0n
- Page: https://www.luxalgo.com/library/indicator/distribution-moments/

**Distribution Moments** turns a rolling window of returns into the numbers that describe its shape (mean, variance and standard deviation, skewness, and kurtosis), plotting one of them in the pane while a dashboard reports them all. Built as the reference implementation of [distribution moments](https://www.luxalgo.com/library/concept/distribution-moments/) for charts, it computes log returns of the close over 252 bars by default, plots skewness against a dotted reference level, and fires alerts when asymmetry or tail weight crosses your thresholds.

## How to Trade the Distribution Moments?

- **Skewness at or below -0.5**: the dashboard flags Left Tail (recent surprises lean downside); readings at or above +0.5 flag Right Tail.
- **Kurtosis above 3**: heavier tails than the normal benchmark, an argument for wider stops and smaller size.
- **Std Dev row**: per-bar return dispersion, the scale the shape numbers are standardized by.
- **Regime drift**: watch the plotted moment's trend rather than single prints. Return shape tells you how far to trust the other [statistical tools](https://www.luxalgo.com/library/family/statistics/).

## Distribution Moments Settings

- **Source** (default close): series the return sample is built from.
- **Return Type** (default Log): log returns are standard; Simple for comparison.
- **Window Length** (default 252): returns in the rolling sample. Higher moments want hundreds of observations.
- **Plotted Moment** (default Skewness): which of the five series the pane displays.
- **Kurtosis Convention** (default Raw (Normal = 3)): Raw benchmarks normal at 3; Excess subtracts that 3.
- **Skewness Alert Threshold** (default 0.5): absolute level for the tail alerts and dashboard read.
- **Kurtosis Alert Threshold** (default 3.0): raw kurtosis level marking fat tails.
- **Show Dashboard** (default enabled) and **Gradient Fill** (default enabled) round out the pane.

## Frequently Asked Questions

### Why not just watch standard deviation?

Because it is only the second moment. [Standard Deviation](https://www.luxalgo.com/library/indicator/standard-deviation/) measures dispersion but says nothing about which side the outliers favor or how heavy the tails run. Identical volatility can hide very different downside risk.

### Why did a reading jump with no obvious news?

The third and fourth moments raise each deviation to the 3rd and 4th power, handing a single extreme bar outsized influence. A reading can lurch when an old outlier drops out of the 252-bar sample, an artifact of the window, not fresh information.

### Should I use raw or excess kurtosis?

They differ by exactly 3, nothing more: Raw benchmarks the normal distribution at 3, Excess at 0. Pick whichever convention your other sources use. The alerts evaluate raw kurtosis either way.

## Related indicators

- [Reversal Probability Zone & Levels](https://www.luxalgo.com/library/indicator/reversal-probability-zone-levels/) (Percentile Rank): markdown at https://www.luxalgo.com/library/indicator/reversal-probability-zone-levels.md
- [Consecutive Candle Streak Analysis](https://www.luxalgo.com/library/indicator/consecutive-candle-streak-analysis/) (Distribution-of-returns Profiling): markdown at https://www.luxalgo.com/library/indicator/consecutive-candle-streak-analysis.md
- [Probability Grid](https://www.luxalgo.com/library/indicator/probability-grid/) (Distribution-of-returns Profiling): markdown at https://www.luxalgo.com/library/indicator/probability-grid.md
- [Change-Point Detection (CUSUM)](https://www.luxalgo.com/library/indicator/change-point-detection-cusum/) (Outlier Detection): markdown at https://www.luxalgo.com/library/indicator/change-point-detection-cusum.md
- [Standardized Cumulative Deltas](https://www.luxalgo.com/library/indicator/standardized-cumulative-deltas/) (Z-score): markdown at https://www.luxalgo.com/library/indicator/standardized-cumulative-deltas.md
- [Sigmoid Transition Trailing Stop](https://www.luxalgo.com/library/indicator/sigmoid-transition-trailing-stop/) (Sigmoid/softmax Transforms): markdown at https://www.luxalgo.com/library/indicator/sigmoid-transition-trailing-stop.md
- [ATR Exceedance Probability Model](https://www.luxalgo.com/library/indicator/atr-exceedance-probability-model/) (Distribution-of-returns Profiling): markdown at https://www.luxalgo.com/library/indicator/atr-exceedance-probability-model.md
- [Percentile Nearest Rank Using Arrays](https://www.luxalgo.com/library/indicator/percentile-nearest-rank-using-arrays/) (Percentile Rank): markdown at https://www.luxalgo.com/library/indicator/percentile-nearest-rank-using-arrays.md

---

Source: https://www.luxalgo.com/library/indicator/distribution-moments/ (LuxAlgo Library). Free to use with attribution: https://www.luxalgo.com/library/license/
