OPEN-SOURCE SCRIPT
ATR Risk Display - Multi Futures

What This Does
I got tired of manually calculating my ATR stops and risk for different futures contracts, especially when switching between ES, NQ, and their micro versions. This indicator automatically detects what futures symbol you're trading and shows you the exact tick count and dollar risk for your stop loss.
The Problem It Solves
If you trade futures with ATR-based stops, you know the hassle:
This handles all of that automatically.
Key Features
How to Use
The display will show something like: "ES ATR(5) × 1.5 = 12 ticks ($150)"
Settings Explained
Supported Futures
Notes
Why This Exists
I use ATR trailing stops on all my trades and got tired of doing mental math every time I switched between charts or contracts. Especially useful if you trade both full-size and micro contracts - the risk difference is huge and easy to mess up.
Hope this helps your trading! Feel free to suggest improvements.
I got tired of manually calculating my ATR stops and risk for different futures contracts, especially when switching between ES, NQ, and their micro versions. This indicator automatically detects what futures symbol you're trading and shows you the exact tick count and dollar risk for your stop loss.
The Problem It Solves
If you trade futures with ATR-based stops, you know the hassle:
- Different contracts have different tick values
- You need to calculate position risk in dollars
- Switching between symbols means redoing all the math
- Renko charts make it even more confusing since ATR needs to come from regular candles
This handles all of that automatically.
Key Features
- Auto-detects futures symbols - ES, NQ, YM, RTY, GC, CL, and all the micros (MES, MNQ, etc.)
- Shows everything you need in one line: ATR(timeframe) × multiplier = X ticks ($XXX)
- Works on Renko charts - pulls ATR from regular timeframe charts (super important if you use Renko)
- Adjustable position sizing - set your contract count and see total risk instantly
- Clean, minimal display - just the info you need, no clutter
How to Use
- Add it to any futures chart
- Set your preferred ATR timeframe (I use 5-minute)
- Set your ATR multiplier (I use 1.5x for my stops)
- Set your contract size
- That's it - the indicator handles the rest
The display will show something like: "ES ATR(5) × 1.5 = 12 ticks ($150)"
Settings Explained
- ATR Timeframe: What timeframe to calculate ATR from (always uses regular candles, even on Renko)
- ATR Multiplier: How many ATRs for your stop (1.5 is common, 2.0 for wider stops)
- Number of Contracts: Your position size for risk calculation
- Auto-Detect Symbol: Leave on unless you want to manually override
Supported Futures
- Full size: ES, NQ, YM, RTY, GC, CL, ZB, ZN, 6E, 6J
- Micros: MES, MNQ, MYM, M2K, MGC, MCL
Notes
- Made this primarily for my own ES trading but figured others might find it useful
- The tick values are based on standard CME specs
- If you trade other futures, you can modify the code to add them
- Works great alongside level indicators for risk management
Why This Exists
I use ATR trailing stops on all my trades and got tired of doing mental math every time I switched between charts or contracts. Especially useful if you trade both full-size and micro contracts - the risk difference is huge and easy to mess up.
Hope this helps your trading! Feel free to suggest improvements.
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.