# Multi-Length Stochastic Average

Averages stochastic oscillators of every length from 4 up to your chosen maximum into a single 0-100 line, so one reading reflects price's position inside every rolling high-low range in the span at once. Prints 0 at all rolling lows and 100 at all rolling highs, with circles marking 20/80 crossings and pre- and post-smoothing configurable at each stage.

- Indicator in the LuxAlgo Library, by LuxAlgo, published Sep 20, 2021.
- Access: free.
- Concepts: [Stochastic Oscillator](https://www.luxalgo.com/library/concept/stochastic-oscillator/) (primary)
- Open on Vela: https://vela.luxalgo.com/chart?pineScriptCodeId=cmpwn3xgb005ivhsgcxg0q0hf
- Page: https://www.luxalgo.com/library/indicator/multi-length-stochastic-average/

**Multi-Length Stochastic Average** blends [stochastic oscillators](https://www.luxalgo.com/library/concept/stochastic-oscillator/) of every period from 4 up to a user-defined maximum into one average. The payoff is double: an oscillator more reactive than any single long lookback, and a direct read on where price sits relative to rolling maximums and minimums across the whole span of periods. The line prints 0 only when price matches every rolling minimum in the range, and 100 only when it matches every rolling maximum.

## How to Trade the Multi-Length Stochastic Average?

- **Crosses of the 20/80 levels**: marked with circles. These transitions time trades better than watching slope alone or waiting for the 50 mark to give way.
- **Extremes at 0 or 100**: every measured lookback agrees price is pinned to its lows or highs, the strongest statement of stretch the tool can make.
- **Direction and strength**: read it like any bounded oscillator from the [momentum family](https://www.luxalgo.com/library/family/momentum/); sustained readings on one side of 50 accompany trending conditions.

Pre-smoothing the source (a 20-period simple average, for instance) makes the color coding and crossing circles more pronounced. Stay alert to retracements inside a trend, which can bend the oscillator without ending the move.

## Multi-Length Stochastic Average Settings

- **Length**: the largest stochastic period included; every period from 4 up to it contributes to the average.
- **Source**: the series the stochastics are computed from.
- **Pre-Smoothing (1st Input)**: how much smoothing hits the source before calculation.
- **Pre-Smoothing (2nd Input)**: the pre-smoothing method.
- **Post-Smoothing (1st Input)**: smoothing applied to the finished oscillator.
- **Post-Smoothing (2nd Input)**: the post-smoothing method.

Available methods are a simple, triangular, or least-squares moving average, plus "None" for raw output; the least-squares option can overshoot when used for post-smoothing.

## Frequently Asked Questions

### How does it differ from a single-length Stochastic?
A [single-length Stochastic](https://www.luxalgo.com/library/indicator/stochastic/) scores price against one window's range; this average polls every window from 4 bars up to your maximum, embedding short- and long-term positioning in the same line. The result is harder for one arbitrary length choice to distort.

### Which smoothing settings should I start with?
Raw output shows the concept most clearly; add pre-smoothing when you want the circles and color coding to stand out, and post-smoothing when the final line itself is too jittery.

### Where can I get the Multi-Length Stochastic Average?
It is free through the LuxAlgo Library, and from this page you can have Quant, our coding agent, run it while you experiment with the smoothing inputs. You can also copy the source code from this page and run it anywhere Pine Script® runs.

## Related indicators

- [Inertial Stochastic](https://www.luxalgo.com/library/indicator/inertial-stochastic/) (Stochastic Oscillator): markdown at https://www.luxalgo.com/library/indicator/inertial-stochastic.md
- [Stochastic Adaptive %D](https://www.luxalgo.com/library/indicator/stochastic-adaptive-d/) (Stochastic Oscillator): markdown at https://www.luxalgo.com/library/indicator/stochastic-adaptive-d.md
- [Circular Barplot - Oscillators Sentiment](https://www.luxalgo.com/library/indicator/circular-barplot-oscillators-sentiment/) (Stochastic Oscillator): markdown at https://www.luxalgo.com/library/indicator/circular-barplot-oscillators-sentiment.md
- [Normalized Oscillators Spider Chart](https://www.luxalgo.com/library/indicator/normalized-oscillators-spider-chart/) (Stochastic Oscillator): markdown at https://www.luxalgo.com/library/indicator/normalized-oscillators-spider-chart.md
- [Stochastic](https://www.luxalgo.com/library/indicator/stochastic/) (Stochastic Oscillator): markdown at https://www.luxalgo.com/library/indicator/stochastic.md
- [Double Stochastic](https://www.luxalgo.com/library/indicator/double-stochastic/) (Momentum & Oscillators): markdown at https://www.luxalgo.com/library/indicator/double-stochastic.md
- [Stochastic Pop](https://www.luxalgo.com/library/indicator/stochastic-pop/) (Momentum & Oscillators): markdown at https://www.luxalgo.com/library/indicator/stochastic-pop.md
- [SMI Ergodic](https://www.luxalgo.com/library/indicator/smi-ergodic/) (Stochastic Momentum Index): markdown at https://www.luxalgo.com/library/indicator/smi-ergodic.md

---

Source: https://www.luxalgo.com/library/indicator/multi-length-stochastic-average/ (LuxAlgo Library). Free to use with attribution: https://www.luxalgo.com/library/license/
