OPEN-SOURCE SCRIPT
CHAN CRYPTO RS

🩷 ATR RS (Crypto / High-based 2.1x, Decimal Safe v2)
This indicator is designed for crypto position sizing and stop calculation using ATR-based risk management. It helps traders automatically determine the stop price, per-unit risk, and optimal position size based on a fixed risk amount in USDT.
🔧 Core Logic
ATR Length (Daily RMA) — calculates the daily Average True Range (ATR) using RMA smoothing.
ATR Multiplier (2.1× default) — defines how far the stop is placed from the daily high.
Stop Price (for Longs) = Daily High − ATR × Multiplier
Per-Unit Risk = (Entry − Stop) × Point Value
Position Size = Risk Amount ÷ Per-Unit Risk
Automatically handles decimal precision for micro-priced crypto assets (e.g., PEPE, SHIB).
Includes safeguards for minimum size and maximum position caps.
💡 Features
Uses Daily ATR without lookahead (no repainting).
Dynamically switches between current and previous ATR for stable results when the daily bar isn’t yet confirmed.
“Snap to tick” ensures stop prices align with the symbol’s tick size.
Table display summarizes ATR, stop price, per-unit risk, total risk, size, and bet amount.
Optional stop label on the chart for visual clarity.
🧮 Output Table
Metric Description
ATR(10) Daily RMA-based ATR
ATR used Chosen ATR (current or previous)
Stop Calculated stop price
Per-unit Risk per coin/unit
Risk Total risk in USDT
Size Optimal position size
Bet Total position value (Entry × Size)
🧠 Ideal For
Crypto traders who use fixed-risk ATR strategies and need precise, decimal-safe position sizing even for ultra-low-priced tokens.
This indicator is designed for crypto position sizing and stop calculation using ATR-based risk management. It helps traders automatically determine the stop price, per-unit risk, and optimal position size based on a fixed risk amount in USDT.
🔧 Core Logic
ATR Length (Daily RMA) — calculates the daily Average True Range (ATR) using RMA smoothing.
ATR Multiplier (2.1× default) — defines how far the stop is placed from the daily high.
Stop Price (for Longs) = Daily High − ATR × Multiplier
Per-Unit Risk = (Entry − Stop) × Point Value
Position Size = Risk Amount ÷ Per-Unit Risk
Automatically handles decimal precision for micro-priced crypto assets (e.g., PEPE, SHIB).
Includes safeguards for minimum size and maximum position caps.
💡 Features
Uses Daily ATR without lookahead (no repainting).
Dynamically switches between current and previous ATR for stable results when the daily bar isn’t yet confirmed.
“Snap to tick” ensures stop prices align with the symbol’s tick size.
Table display summarizes ATR, stop price, per-unit risk, total risk, size, and bet amount.
Optional stop label on the chart for visual clarity.
🧮 Output Table
Metric Description
ATR(10) Daily RMA-based ATR
ATR used Chosen ATR (current or previous)
Stop Calculated stop price
Per-unit Risk per coin/unit
Risk Total risk in USDT
Size Optimal position size
Bet Total position value (Entry × Size)
🧠 Ideal For
Crypto traders who use fixed-risk ATR strategies and need precise, decimal-safe position sizing even for ultra-low-priced tokens.
Open-source script
In true TradingView spirit, the creator of this script has made it open-source, so that traders can review and verify its functionality. Kudos to the author! While you can use it for free, remember that republishing the code is subject to our House Rules.
Disclaimer
The information and publications are not meant to be, and do not constitute, financial, investment, trading, or other types of advice or recommendations supplied or endorsed by TradingView. Read more in the Terms of Use.
Open-source script
In true TradingView spirit, the creator of this script has made it open-source, so that traders can review and verify its functionality. Kudos to the author! While you can use it for free, remember that republishing the code is subject to our House Rules.
Disclaimer
The information and publications are not meant to be, and do not constitute, financial, investment, trading, or other types of advice or recommendations supplied or endorsed by TradingView. Read more in the Terms of Use.