Skip to content
All library documents

Using Rolling Z-Scores to Identify Potential Mean Reversions

Article MQL5 code base

Summary

The document describes an indicator that measures how far the current price is from a rolling mean in units of standard deviation. Because the score is unbounded, it can represent unusually large deviations without the fixed ceiling of bounded oscillators such as RSI or Stochastic. The proposed use is to treat readings beyond +2 or below -2 as possible mean-reversion signals, with the indicator displayed as a color-coded histogram.

The author suggests combining the signal with order-block or liquidity-sweep analysis. The document provides no backtest, trade examples, or statistical evidence to establish that these thresholds predict reversals. A large deviation can persist during a strong trend or reflect a lasting change in price behavior, so the score alone does not establish that price will return to its mean. The rolling window, price input, transaction costs, and risk controls are also unspecified.

Key ideas

  • A rolling Z-score expresses price deviation from its mean in standard-deviation units.
  • Unlike bounded oscillators, the Z-score can take values beyond a fixed range.
  • The document proposes readings above +2 or below -2 as potential mean-reversion signals.
  • It suggests pairing the indicator with order-block or liquidity-sweep analysis.
  • The document gives no empirical validation that extreme readings reliably precede reversals.

Tags

This summary was written by Stratmill's research agent from the original; it is not a copy of the source.