OPEN-SOURCE SCRIPT
Cập nhật ScalpMap - EMA Pivot Targets

ScalpMap is a lightweight target-mapping tool designed for NQ scalping. It highlights nearby pivot-derived scalp levels on the correct side of EMA bias.
Asset designed for:
NQ / MNQ futures
Recommended timeframe:
15 seconds to 1 minute, depending on volatility.
In higher volatility conditions, lower timeframes may provide more responsive levels.
In lower volatility conditions, higher timeframes may help reduce noise.
The tool uses EMA34 as the main directional filter. When price is trading above the EMA with sufficient separation, the bias favours long-side setups. When price is trading below the EMA with sufficient separation, the bias favours short-side setups.
The plotted levels are generated from two pivot layers:
Pivot levels are filtered to reduce clutter and avoid plotting multiple levels too close together. Levels can also flip from resistance to support, or support to resistance, after confirmed close-through behaviour. This helps the tool focus on the most relevant levels around current price.
Core trade logic:
Visual guide:
This script is intended as a visual decision-support tool only. It does not provide buy or sell signals and should be used together with your own trade plan and risk management.
Asset designed for:
NQ / MNQ futures
Recommended timeframe:
15 seconds to 1 minute, depending on volatility.
In higher volatility conditions, lower timeframes may provide more responsive levels.
In lower volatility conditions, higher timeframes may help reduce noise.
The tool uses EMA34 as the main directional filter. When price is trading above the EMA with sufficient separation, the bias favours long-side setups. When price is trading below the EMA with sufficient separation, the bias favours short-side setups.
The plotted levels are generated from two pivot layers:
- Tight close-based pivots for local structure.
- Wider wick-based pivots for larger rejection points.
Pivot levels are filtered to reduce clutter and avoid plotting multiple levels too close together. Levels can also flip from resistance to support, or support to resistance, after confirmed close-through behaviour. This helps the tool focus on the most relevant levels around current price.
Core trade logic:
- Take trades only on the correct side of the EMA.
- Avoid entries directly into clustered levels where price is likely to chop producing lower R trades whilst the EMA is rounding.
- Look for cleaner impulse scalp opportunities when price breaks through level and has open space toward the next spread-out target.
Visual guide:
- Blue levels mark upper targets / resistance-side levels.
- Red levels mark lower targets / support-side levels.
- The orange line is the EMA34 bias line.
This script is intended as a visual decision-support tool only. It does not provide buy or sell signals and should be used together with your own trade plan and risk management.
Phát hành các Ghi chú
Improved how ScalpMap maintains target levels after strong directional moves.Previously, when price cleared or retired existing pivot levels, the script could temporarily lose active upper or lower targets. The target engine now includes fallback extension logic so projected levels continue to populate even when price breaks beyond the existing pivot structure.
- Improved target continuity after strong breakouts.
- Added fallback extension levels when no valid pivot anchor is available.
- Reduced situations where the chart may show no active target levels after price clears nearby structure.
Phát hành các Ghi chú
Update v0.3 - Synthetic Target Levels- Added synthetic extension targets for ATH conditions.
When price moves beyond known pivot structure, ScalpMap now seeds projected target levels from current price using ATR-based spacing. This helps maintain active upper and lower scalp targets during strong impulse moves when no confirmed pivot levels exist beyond price.
Phát hành các Ghi chú
V0.4 Update - optimized for faster loading and reduced script overhead.- Removed unused pivot metadata and pivot ageing logic.
- Improved array handling using persistent scratch arrays.
- Reduced repeated pivot scanning with early loop exits.
- Improved level coloring logic so color follows live price position more cleanly.
Note: Stored pivot levels are capped for performance. In some conditions, older valid pivots may drop from the active map and be replaced by ATR-based extension levels. These are useful guide levels, but may be less significant than real historical structure. Check further back on the chart or use a higher timeframe for stronger target context.
Phát hành các Ghi chú
V0.5- Fixed H/L target classification bug from v0.4.
Mã nguồn mở
Theo đúng tinh thần TradingView, tác giả của tập lệnh này đã công bố nó dưới dạng mã nguồn mở, để các nhà giao dịch có thể xem xét và xác minh chức năng. Chúc mừng tác giả! Mặc dù bạn có thể sử dụng miễn phí, hãy nhớ rằng việc công bố lại mã phải tuân theo Nội quy.
Thông báo miễn trừ trách nhiệm
Thông tin và các ấn phẩm này không nhằm mục đích, và không cấu thành, lời khuyên hoặc khuyến nghị về tài chính, đầu tư, giao dịch hay các loại khác do TradingView cung cấp hoặc xác nhận. Đọc thêm tại Điều khoản Sử dụng.
Mã nguồn mở
Theo đúng tinh thần TradingView, tác giả của tập lệnh này đã công bố nó dưới dạng mã nguồn mở, để các nhà giao dịch có thể xem xét và xác minh chức năng. Chúc mừng tác giả! Mặc dù bạn có thể sử dụng miễn phí, hãy nhớ rằng việc công bố lại mã phải tuân theo Nội quy.
Thông báo miễn trừ trách nhiệm
Thông tin và các ấn phẩm này không nhằm mục đích, và không cấu thành, lời khuyên hoặc khuyến nghị về tài chính, đầu tư, giao dịch hay các loại khác do TradingView cung cấp hoặc xác nhận. Đọc thêm tại Điều khoản Sử dụng.