Price Rank Shift
Compare two blocks of closes to identify broad price relocation and later loss of ordering.
- Pairwise rank comparison
- Median-displacement filter
- Persistent direction and neutralization
About this indicator
The default comparison uses two separate blocks of 20 closes. Pairwise ordering produces a signed rank effect; direction also requires a median displacement of at least 0.50 prior ATR and three confirming closes. A weaker ordering threshold governs neutralization.
The two median lines roll forward. They are not fixed support or stop levels. Within-block ordering is ignored, so an Up state can persist during a pullback. Rank effect is descriptive, not forecast probability or statistical significance.
TradingView download: the branded Harmony Algo Community Pine Script TXT. Paste the complete file into Pine Editor, save and add to a standard candle chart. The official link opens the clean public TradingView publication.
MT5 download: the compiled, branded Community EX5. Place it in MQL5/Indicators and refresh the MT5 Navigator. Source is provided separately in the Community package. Defaults were checked on loaded EURUSD and GBPUSD H1/H4 history. Local alerts are disabled by default; real-time alert delivery, live ticks, profitability and exact cross-feed TradingView signal equality were not verified.