Harbor Reversal Ledger [JOAT]Harbor Reversal Ledger
Introduction
Harbor Reversal Ledger is an open-source reversal timing indicator that combines completed higher-timeframe candle context with confirmed local RSI divergence.
The objective is not to predict turning points early.
The objective is to wait for enough evidence that a reversal thesis is becoming structurally credible.
Many reversal tools repaint because they depend on unfinished higher-timeframe candles or unconfirmed pivot comparisons.
Harbor Reversal Ledger avoids that by:
requesting completed higher-timeframe candles only
confirming RSI pivots before evaluating divergence
scoring confluence from multiple independent ingredients
projecting higher-timeframe structure onto the execution chart
rendering a timing ledger in its own pane
Core Concepts
1. Completed Higher-Timeframe Context
The script requests prior higher-timeframe candles rather than reading the currently forming candle.
This keeps the higher-timeframe pattern engine stable and non-repainting.
2. Candle Pattern Recognition
Bullish and bearish engulfing patterns can be enabled, and pin-bar style rejection patterns can also be used.
These patterns contribute directional context, not automatic entries.
3. Confirmed RSI Divergence
Local price and RSI pivots are both confirmed using left/right pivot logic.
Only after the pivots are locked does the script compare price progression against RSI progression to determine bullish or bearish divergence.
4. Distance-to-Extreme Scoring
Reversal evidence becomes more meaningful when price is still close to a recent extreme.
The confluence engine therefore includes distance-based scoring relative to a configurable lookback.
5. Projection and Confluence Zones
Completed higher-timeframe candles can be projected forward on the execution chart, while divergence events can create local confluence zones when the evidence stack is strong enough.
Features
Completed HTF candle projection: prior higher-timeframe range and body projected onto the chart
HTF pattern engine: bullish and bearish engulfing and pin-bar style patterns
Confirmed RSI divergence: bullish and bearish divergence using pivot confirmation
Dual-pane logic: overlay objects explain price context while the pane acts as a reversal timing ledger
Confluence scoring: combines HTF pattern, local divergence, and distance-to-extreme logic
Premium/discount context: position of price relative to the HTF midpoint is plotted
Confluence zones: optional chart zones highlight stronger bullish or bearish reversal regions
State-based RSI coloring: RSI line color reflects the current net confluence
Top-right dashboard: summarizes pattern state, divergence state, confluence, and location context
Non-repainting design: no unfinished HTF candles and no unconfirmed pivot divergence
Input Parameters
Higher Timeframe Context
HTF Candle Source
Enable Engulfing Patterns
Enable Pin Bar Patterns
Project Completed HTF Candle
Projection Offset Bars
Projection Width Bars
Execution Divergence
RSI Length
Pivot Left
Pivot Right
Show Divergence Lines
Show Confluence Zones
Confluence Engine
Distance Lookback
Distance Weight
Pattern Weight
Divergence Weight
Display
Show RSI State Fill
Dashboard Position
Dashboard Size
How to Use This Indicator
Step 1: Start With the Higher-Timeframe Projection
Use the projected completed candle to understand whether the larger reference bar is signaling rejection, acceptance, or neutrality.
Step 2: Wait for Local Divergence Confirmation
The script intentionally waits for confirmed pivots.
That delay is a feature, not a flaw.
Step 3: Read the Net Confluence, Not Just RSI
The pane is not meant to be treated like a normal RSI oscillator.
Its color and context matter because they reflect the broader reversal evidence stack.
Step 4: Use Confluence Zones as Areas of Interest
Zones identify places where the higher-timeframe context and local divergence align.
They are not guaranteed turning points.
Step 5: Respect the Directional Imbalance
If the higher-timeframe candle context is strongly bearish, a minor bullish divergence alone may not be enough to justify a reversal thesis, and vice versa.
Indicator Limitations
Confirmed divergence necessarily appears after the pivot forms, which introduces intentional timing delay
Higher-timeframe pattern quality depends on the selected timeframe and instrument behavior
RSI divergence can persist without immediate reversal in strong directional markets
Projection objects are context tools, not price targets
Originality Statement
Harbor Reversal Ledger is designed as a confluence ledger rather than a single-pattern reversal marker.
Its distinguishing structure comes from pairing completed higher-timeframe candle analysis, confirmed divergence, distance scoring, projected context, and pane-based confluence visualization into one disciplined, non-repainting timing framework.
Disclaimer
This indicator is provided for educational and informational purposes only.
It is not financial advice and should not be used as a standalone reason to enter or exit a market.
All reversal readings are based on historical chart data and can fail, especially in strongly trending or event-driven conditions.
Use proper risk management and independent judgment.
Pine Script® indicator






















