PROTECTED SOURCE SCRIPT
Range Finder (PUBLIC)

Purpose: Draws a single “current range” (Upper, Lower, Median, 25%, 75%) based on the selected range timeframe: W / D1 / H4.
Range construction (initial):
Finds the latest significant pivot high (Upper) and pivot low (Lower) on the selected range TF (using configurable left/right pivot bars).
Calculates:
Median = (Upper + Lower) / 2
25% = Lower + 0.25 × (Upper−Lower)
75% = Lower + 0.75 × (Upper−Lower)
Draws horizontal lines from the range start to “now” (no infinite extension).
Range validity rule (no nested ranges):
Once a range is set, it does not change unless a strong break occurs.
“Strong break” is defined as a confirmed swing (not just closes):
Break-down: a confirmed swing low below the Lower threshold
Break-up: a confirmed swing high above the Upper threshold
Swing confirmation uses a window-extreme method (robust to equal highs/lows), controlled by Strong break swing left/right (default 3-candle swing = 1/1).
Optional buffer % can be applied to Upper/Lower to avoid tiny overshoots.
New range after a break:
After a break-down, it stores the break swing low as new Lower candidate, then waits for a confirmed swing high after that low that is still outside the old range to become the new Upper, then locks the new range.
After a break-up, it stores the break swing high as new Upper candidate, then waits for a confirmed swing low after that high still outside the old range to become the new Lower, then locks the new range.
If a new lower low (or higher high) forms while rebuilding, it updates the candidate and restarts the “wait for opposite swing” step.
High-probability zones (optional):
Only highlights 0–30% (Lower to 30%) and 70–100% (70% to Upper).
The fill appears only when current price is inside one of those zones.
Colors + opacity are user-configurable.
Dashboard (optional):
Shows selected range TF (W/D1/H4).
Shows D1 range size % and warns visually if D1 range exceeds a set threshold (default 14%).
In H4 mode, warning is suppressed (shows status only).
Position and text colors are configurable.
Range construction (initial):
Finds the latest significant pivot high (Upper) and pivot low (Lower) on the selected range TF (using configurable left/right pivot bars).
Calculates:
Median = (Upper + Lower) / 2
25% = Lower + 0.25 × (Upper−Lower)
75% = Lower + 0.75 × (Upper−Lower)
Draws horizontal lines from the range start to “now” (no infinite extension).
Range validity rule (no nested ranges):
Once a range is set, it does not change unless a strong break occurs.
“Strong break” is defined as a confirmed swing (not just closes):
Break-down: a confirmed swing low below the Lower threshold
Break-up: a confirmed swing high above the Upper threshold
Swing confirmation uses a window-extreme method (robust to equal highs/lows), controlled by Strong break swing left/right (default 3-candle swing = 1/1).
Optional buffer % can be applied to Upper/Lower to avoid tiny overshoots.
New range after a break:
After a break-down, it stores the break swing low as new Lower candidate, then waits for a confirmed swing high after that low that is still outside the old range to become the new Upper, then locks the new range.
After a break-up, it stores the break swing high as new Upper candidate, then waits for a confirmed swing low after that high still outside the old range to become the new Lower, then locks the new range.
If a new lower low (or higher high) forms while rebuilding, it updates the candidate and restarts the “wait for opposite swing” step.
High-probability zones (optional):
Only highlights 0–30% (Lower to 30%) and 70–100% (70% to Upper).
The fill appears only when current price is inside one of those zones.
Colors + opacity are user-configurable.
Dashboard (optional):
Shows selected range TF (W/D1/H4).
Shows D1 range size % and warns visually if D1 range exceeds a set threshold (default 14%).
In H4 mode, warning is suppressed (shows status only).
Position and text colors are configurable.
受保護腳本
此腳本以閉源形式發佈。 不過,您可以自由使用,沒有任何限制 — 點擊此處了解更多。
Crypto Scalp & intraweek trades t.co/Lu1b6sNtky
免責聲明
這些資訊和出版物並非旨在提供,也不構成TradingView提供或認可的任何形式的財務、投資、交易或其他類型的建議或推薦。請閱讀使用條款以了解更多資訊。
受保護腳本
此腳本以閉源形式發佈。 不過,您可以自由使用,沒有任何限制 — 點擊此處了解更多。
Crypto Scalp & intraweek trades t.co/Lu1b6sNtky
免責聲明
這些資訊和出版物並非旨在提供,也不構成TradingView提供或認可的任何形式的財務、投資、交易或其他類型的建議或推薦。請閱讀使用條款以了解更多資訊。