Skip to content
All library documents

Price-Range Indicator for Visualizing Short-Term Trend Direction

Article ProRealCode

Summary

This document describes a price-range indicator intended to make trend direction easier to see through colored chart marks. It initializes a reference value from the close, then updates that value when the high falls below it or the low rises above it. Bars whose close is above the reference are drawn in blue, while other bars are drawn in magenta, with the high-to-low range shown for each bar.

The indicator also returns the reference series and two additional series that track it during downward or upward changes. The description provides no formal definition of the range measure, trading rules, or evidence that the colors predict future movement. The supplied logic is difficult to evaluate from the explanation alone, and the code’s upward tracking expression appears potentially inconsistent with its stated purpose. It should therefore be treated as a visualization concept that needs validation before use in a trading system.

Key ideas

  • The indicator updates a reference level using the current bar’s high and low.
  • It colors bars according to whether the close is above or at or below the reference level.
  • It returns the reference series alongside two additional series intended to track directional changes.
  • The document provides no performance evidence, and the indicator logic may need review before implementation.

Tags

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