OPEN-SOURCE SCRIPT
RSI Pigo Fade

RSI Pigo Fade — Multi-Timeframe Extreme Detector
An indicator designed to detect extreme overbought and oversold conditions by
combining traditional RSI with a statistical percentile (KDE-style) across
two simultaneously configurable timeframes.
🎯 PURPOSE
Built specifically for traders looking to fade reversals at target zones
(Fibonacci levels, prior session highs/lows, liquidity sweeps). It filters
REAL RSI extremes from normal trending momentum by analyzing the statistical
position of the current RSI relative to its own recent history.
📊 HOW IT WORKS
The indicator simultaneously analyzes two timeframes (configurable, default
1m and 5m) and calculates two metrics for each:
1. Standard RSI (default 14 periods)
Measures relative price strength on the selected timeframe.
2. KDE Extremity (simplified Kernel Density Estimation)
Calculates how extreme the current RSI is compared to its last 100
historical values. Ranges from 0% (neutral) to 100% (absolute extreme).
- 0% = current RSI sits at the historical median
- 50% = current RSI is at the 25th or 75th percentile
- 100% = current RSI is at the absolute extreme of recent history
The metric uses ta.percentrank() to ensure consistency across different
timeframes. Values remain identical regardless of which chart you're
currently viewing.
🔔 SIGNALS
The indicator triggers alerts when both conditions are met simultaneously:
🔴 BOTH OVERBOUGHT
- RSI ≥ upper threshold in both TFs
- KDE Extremity ≥ defined threshold in both TFs
- Suggests potential ceiling / SHORT candidate at target zones
🟢 BOTH OVERSOLD
- RSI ≤ lower threshold in both TFs
- KDE Extremity ≥ defined threshold in both TFs
- Suggests potential floor / LONG candidate at target zones
Individual TF alerts are also available for early detection.
⚙️ RECOMMENDED CONFIGURATION
For assets with persistent trends (NQ, ES, S&P futures):
- RSI High: 75 / RSI Low: 25
- KDE TF1: 75% / KDE TF2: 65%
For assets with more predictable reversals (Gold, EUR/USD, swing trading):
- RSI High: 70 / RSI Low: 30
- KDE TF1: 70% / KDE TF2: 60%
Asymmetric thresholds (TF2 lower than TF1) reflect the fact that fast TFs
reach extremes before slow ones. TF2 acts as confirmation — it doesn't need
to reach the same absolute extreme as TF1.
📋 DASHBOARD
Real-time display:
- TF (configured timeframe)
- RSI value
- KDE % (statistical extremity)
- Aggregated status: BOTH OVERBOUGHT / BOTH OVERSOLD / Partial / Neutral
Values are color-coded based on conditions: coral red for overbought,
turquoise green for oversold.
🎓 RECOMMENDED USE
This indicator is NOT an automatic entry trigger. It's a quality filter that
confirms statistical extremes. For maximum effectiveness, combine with:
- Technical zone analysis (Fibonacci, prior support/resistance)
- Structural confirmation (BOS, FVGs, session manipulation)
- Multi-timeframe trend and extension indicators
BOTH signals are rare by design. Their scarcity is what makes them valuable.
⚠️ LIMITATIONS
- Requires ~30 seconds at load to build statistical history
- In markets breaking out from prolonged lateral ranges, may give premature
signals (KDE marks extreme but structurally it's nascent momentum).
Combine with trend analysis to avoid this trap.
- Does not work well in illiquid markets or those with large gaps
🔧 CUSTOMIZATION
All parameters are configurable: RSI length, KDE lookback, kernel type
(Gaussian/Uniform/Sigmoid), bandwidth, dashboard position, colors. Adaptable
to any instrument and operational timeframe.
═══════════════════════════════════════════════════════════════
Version: 1.0
Compatibility: Pine Script v6
Type: Overlay with dashboard
═══════════════════════════════════════════════════════════════
An indicator designed to detect extreme overbought and oversold conditions by
combining traditional RSI with a statistical percentile (KDE-style) across
two simultaneously configurable timeframes.
🎯 PURPOSE
Built specifically for traders looking to fade reversals at target zones
(Fibonacci levels, prior session highs/lows, liquidity sweeps). It filters
REAL RSI extremes from normal trending momentum by analyzing the statistical
position of the current RSI relative to its own recent history.
📊 HOW IT WORKS
The indicator simultaneously analyzes two timeframes (configurable, default
1m and 5m) and calculates two metrics for each:
1. Standard RSI (default 14 periods)
Measures relative price strength on the selected timeframe.
2. KDE Extremity (simplified Kernel Density Estimation)
Calculates how extreme the current RSI is compared to its last 100
historical values. Ranges from 0% (neutral) to 100% (absolute extreme).
- 0% = current RSI sits at the historical median
- 50% = current RSI is at the 25th or 75th percentile
- 100% = current RSI is at the absolute extreme of recent history
The metric uses ta.percentrank() to ensure consistency across different
timeframes. Values remain identical regardless of which chart you're
currently viewing.
🔔 SIGNALS
The indicator triggers alerts when both conditions are met simultaneously:
🔴 BOTH OVERBOUGHT
- RSI ≥ upper threshold in both TFs
- KDE Extremity ≥ defined threshold in both TFs
- Suggests potential ceiling / SHORT candidate at target zones
🟢 BOTH OVERSOLD
- RSI ≤ lower threshold in both TFs
- KDE Extremity ≥ defined threshold in both TFs
- Suggests potential floor / LONG candidate at target zones
Individual TF alerts are also available for early detection.
⚙️ RECOMMENDED CONFIGURATION
For assets with persistent trends (NQ, ES, S&P futures):
- RSI High: 75 / RSI Low: 25
- KDE TF1: 75% / KDE TF2: 65%
For assets with more predictable reversals (Gold, EUR/USD, swing trading):
- RSI High: 70 / RSI Low: 30
- KDE TF1: 70% / KDE TF2: 60%
Asymmetric thresholds (TF2 lower than TF1) reflect the fact that fast TFs
reach extremes before slow ones. TF2 acts as confirmation — it doesn't need
to reach the same absolute extreme as TF1.
📋 DASHBOARD
Real-time display:
- TF (configured timeframe)
- RSI value
- KDE % (statistical extremity)
- Aggregated status: BOTH OVERBOUGHT / BOTH OVERSOLD / Partial / Neutral
Values are color-coded based on conditions: coral red for overbought,
turquoise green for oversold.
🎓 RECOMMENDED USE
This indicator is NOT an automatic entry trigger. It's a quality filter that
confirms statistical extremes. For maximum effectiveness, combine with:
- Technical zone analysis (Fibonacci, prior support/resistance)
- Structural confirmation (BOS, FVGs, session manipulation)
- Multi-timeframe trend and extension indicators
BOTH signals are rare by design. Their scarcity is what makes them valuable.
⚠️ LIMITATIONS
- Requires ~30 seconds at load to build statistical history
- In markets breaking out from prolonged lateral ranges, may give premature
signals (KDE marks extreme but structurally it's nascent momentum).
Combine with trend analysis to avoid this trap.
- Does not work well in illiquid markets or those with large gaps
🔧 CUSTOMIZATION
All parameters are configurable: RSI length, KDE lookback, kernel type
(Gaussian/Uniform/Sigmoid), bandwidth, dashboard position, colors. Adaptable
to any instrument and operational timeframe.
═══════════════════════════════════════════════════════════════
Version: 1.0
Compatibility: Pine Script v6
Type: Overlay with dashboard
═══════════════════════════════════════════════════════════════
オープンソーススクリプト
TradingViewの精神に則り、このスクリプトの作者はコードをオープンソースとして公開してくれました。トレーダーが内容を確認・検証できるようにという配慮です。作者に拍手を送りましょう!無料で利用できますが、コードの再公開はハウスルールに従う必要があります。
免責事項
これらの情報および投稿は、TradingViewが提供または承認する金融、投資、取引、またはその他の種類の助言もしくは推奨であることを意図したものではなく、またこれらに該当するものでもありません。詳細は利用規約をご覧ください。
オープンソーススクリプト
TradingViewの精神に則り、このスクリプトの作者はコードをオープンソースとして公開してくれました。トレーダーが内容を確認・検証できるようにという配慮です。作者に拍手を送りましょう!無料で利用できますが、コードの再公開はハウスルールに従う必要があります。
免責事項
これらの情報および投稿は、TradingViewが提供または承認する金融、投資、取引、またはその他の種類の助言もしくは推奨であることを意図したものではなく、またこれらに該当するものでもありません。詳細は利用規約をご覧ください。