Midprice Indicator

Parameters: period = 14 (2–200)

Overview

The Midprice indicator represents market equilibrium through the elegant calculation of the midpoint between periodic highs and lows, offering traders a noise-filtered perspective on price action. By averaging the highest high and lowest low over a specified period using the formula (Highest High + Lowest Low) / 2, this indicator creates a smooth line that represents the theoretical balance point between buying and selling pressures. Unlike indicators that focus solely on closing prices or volume-weighted calculations, Midprice captures the full range of market activity while distilling it into a single, actionable line that acts as a dynamic pivot point.

The power of the Midprice indicator lies in its ability to reveal the true center of market activity without the distortions caused by temporary spikes or flash crashes. During trending markets, price tends to respect the Midprice line as either support in uptrends or resistance in downtrends, with sustained moves above or below this equilibrium point confirming directional bias. In ranging markets, the Midprice often acts as a mean reversion target, with price oscillating around this central value. The indicator's responsiveness can be adjusted through the period parameter - shorter periods create a more reactive line suitable for day trading, while longer periods smooth out fluctuations for position trading.

Interpretation & Trading Signals

Market Equilibrium:

  • Price Above Midprice: Bullish bias, buying pressure dominant
  • Price Below Midprice: Bearish bias, selling pressure dominant
  • Price at Midprice: Market equilibrium, potential decision point
  • Midprice Slope: Rising = uptrend, Falling = downtrend

Trading Strategies:

  • Trend Following: Buy when price crosses above rising Midprice
  • Mean Reversion: Fade extremes, target Midprice as profit level
  • Support/Resistance: Use Midprice as dynamic S/R level
  • Breakout Confirmation: Sustained move beyond Midprice validates breakout

Risk Management:

  • Stop Placement: Use Midprice as trailing stop reference
  • Position Sizing: Distance from Midprice indicates risk level
  • Filter Signals: Combine with momentum indicators for confirmation
  • Market Conditions: Works best in trending/cycling markets

Example Usage

Code examples will be available once the Rust implementation is complete.

Performance Analysis

Related Indicators