OPEN-SOURCE SCRIPT
Overlapping FVG - [Fandesoft Trading Academy]

🧠 Overview
This script plots Higher Timeframe Fair Value Gaps (FVGs) with full visibility and precise placement on lower timeframe charts. Each timeframe (30s–15m) has its own independent toggle, custom label, and box styling, allowing traders to analyze market structures in detail.
🎯 Features
✅ Identifies Fair Value Gaps using a 3-candle logic (candle 1 high vs candle 3 low, and vice versa).
✅ Plots HTF FVG boxes aligned to lower timeframes for intraday analysis.
✅ Supports custom timeframes: 30s to 15m, with individual toggles.
✅ Full visual customization: border color, bullish/bearish box opacity, label font size and color.
✅ Modular inputs to enable or disable specific timeframes for performance.
✅ Uses barstate.isconfirmed logic for stable, non-repainting plots.
⚙️ How It Works
The script requests higher timeframe data via request.security. For each confirmed bar, it checks for FVGs based on:
Bullish FVG: low >= high[2]
Bearish FVG: low[2] >= high
If a gap is detected, a box is plotted between candle 1 and candle 3 using box.new().
Timeframe toggles ensure calculations remain within the limit of 40 request.security calls.
📈 Use Cases
Scalpers and intraday traders analyzing microstructure.
ICT methodology practitioners visualizing displacement and inefficiencies.
Traders layering multiple FVG timeframes for confluence.
This script plots Higher Timeframe Fair Value Gaps (FVGs) with full visibility and precise placement on lower timeframe charts. Each timeframe (30s–15m) has its own independent toggle, custom label, and box styling, allowing traders to analyze market structures in detail.
🎯 Features
✅ Identifies Fair Value Gaps using a 3-candle logic (candle 1 high vs candle 3 low, and vice versa).
✅ Plots HTF FVG boxes aligned to lower timeframes for intraday analysis.
✅ Supports custom timeframes: 30s to 15m, with individual toggles.
✅ Full visual customization: border color, bullish/bearish box opacity, label font size and color.
✅ Modular inputs to enable or disable specific timeframes for performance.
✅ Uses barstate.isconfirmed logic for stable, non-repainting plots.
⚙️ How It Works
The script requests higher timeframe data via request.security. For each confirmed bar, it checks for FVGs based on:
Bullish FVG: low >= high[2]
Bearish FVG: low[2] >= high
If a gap is detected, a box is plotted between candle 1 and candle 3 using box.new().
Timeframe toggles ensure calculations remain within the limit of 40 request.security calls.
📈 Use Cases
Scalpers and intraday traders analyzing microstructure.
ICT methodology practitioners visualizing displacement and inefficiencies.
Traders layering multiple FVG timeframes for confluence.
Skrip sumber terbuka
Dalam semangat sebenar TradingView, pencipta skrip ini telah menjadikannya sumber terbuka supaya pedagang dapat menilai dan mengesahkan kefungsiannya. Terima kasih kepada penulis! Walaupun anda boleh menggunakannya secara percuma, ingat bahawa menerbitkan semula kod ini adalah tertakluk kepada Peraturan Dalaman kami.
Penafian
Maklumat dan penerbitan adalah tidak dimaksudkan untuk menjadi, dan tidak membentuk, nasihat untuk kewangan, pelaburan, perdagangan dan jenis-jenis lain atau cadangan yang dibekalkan atau disahkan oleh TradingView. Baca dengan lebih lanjut di Terma Penggunaan.
Skrip sumber terbuka
Dalam semangat sebenar TradingView, pencipta skrip ini telah menjadikannya sumber terbuka supaya pedagang dapat menilai dan mengesahkan kefungsiannya. Terima kasih kepada penulis! Walaupun anda boleh menggunakannya secara percuma, ingat bahawa menerbitkan semula kod ini adalah tertakluk kepada Peraturan Dalaman kami.
Penafian
Maklumat dan penerbitan adalah tidak dimaksudkan untuk menjadi, dan tidak membentuk, nasihat untuk kewangan, pelaburan, perdagangan dan jenis-jenis lain atau cadangan yang dibekalkan atau disahkan oleh TradingView. Baca dengan lebih lanjut di Terma Penggunaan.