Average True Range
systemic:core-atrIndicatorsfunction1 crInputs
| Name | Type | Description |
|---|---|---|
| Window | integer | - **Description**; The number of periods over which the ATR is calculated (commonly set to 14 periods). |
| Price High | floatarray | - **Description**; The highest price reached by the asset during a given period. |
| Price Low | floatarray | - **Description**; The lowest price reached by the asset during a given period. |
| Price Close | floatarray | - **Description**; The price of the asset at the end of the trading period. |
Outputs
| Name | Type | Description |
|---|---|---|
| ATR | floatarray | The **Average True Range (ATR)** output is a time series representing the smoothed average of True Range values over your specified window period. |
A comprehensive guide to using the Average True Range (ATR) for measuring volatility, setting risk levels, and informing trading strategies in both traditional and crypto markets.
Overview
The Average True Range (ATR) is a widely used technical analysis indicator that quantifies market volatility by measuring the range of price movement over a specified period. Developed by J. Welles Wilder Jr. in 1978, ATR is a staple for traders seeking to understand price dynamics, manage risk, and identify breakout opportunities across asset classes—including stocks, commodities, forex, and cryptocurrencies.
Why ATR matters:
- Volatility insight: Captures the degree of price movement, helping traders adapt to changing market conditions.
- Risk management: Used to set stop-loss levels and position sizes based on current volatility.
- Breakout detection: High ATR values often precede or confirm significant price moves.
- Cross-asset utility: Applicable to any liquid market, including 24/7 crypto trading.
Quick links:
- Investopedia: Average True Range (ATR)
- Binance Academy: ATR Indicator
- Fidelity: ATR in Trading
- CME Group: ATR and Volatility
How It Works
ATR measures volatility by considering the greatest of three price ranges for each period:
- Current high minus current low
- Absolute value of current high minus previous close
- Absolute value of current low minus previous close
The True Range (TR) is the maximum of these three values. ATR is then calculated as a moving average (commonly exponential) of the TR over a user-defined window (e.g., 14 days).
Formulas
True Range (TR):
Average True Range (ATR):
Or, for the exponential moving average (EMA) version (Wilder's smoothing):
Where is the lookback period (commonly 14).
Calculation Flow
flowchart TD
A[Price Data: High, Low, Close] --> B[Compute TR for Each Period]
B --> C[Apply Moving Average to TR]
C --> D[Obtain ATR Series]
Interpretation and Use Cases
Typical Ranges
- ATR values: Expressed in price units (e.g., dollars, BTC, etc.), not percent.
- High ATR: Indicates high volatility; price is making large moves.
- Low ATR: Indicates low volatility; price is consolidating or trending smoothly.
Signal Logic
- Rising ATR: Volatility is increasing—often seen before or during breakouts, news events, or trend reversals.
- Falling ATR: Volatility is decreasing—often seen during consolidations or trend exhaustion.
- ATR spikes: Can signal the start of a new trend or a market shock.
Use Case 1: Setting Stop-Losses in Stock Trading
- Scenario: A trader buys Apple stock and sets a stop-loss at 2x the current ATR below the entry price.
- Interpretation: This approach adapts the stop to current volatility, reducing the chance of being stopped out by normal price swings.
- Reference: Fidelity: ATR for Stop-Losses
Use Case 2: Volatility Breakout in Crypto
- Scenario: Bitcoin's ATR rises sharply after a period of low volatility.
- Interpretation: A surge in ATR may precede a breakout; traders may look for confirmation from price action to enter momentum trades.
- Reference: Binance Academy: ATR in Crypto
Use Case 3: Position Sizing in Futures
- Scenario: A futures trader sizes positions so that a 1 ATR move equals 1% of account equity.
- Interpretation: This risk-based sizing helps standardize risk across trades, regardless of market volatility.
- Reference: CME Group: Volatility and Position Sizing
Use Case 4: Comparing Volatility Across Assets
- Scenario: Comparing ATR values of S&P 500, Gold, and Bitcoin to assess which market is most volatile.
- Interpretation: Higher ATR means greater price swings; useful for portfolio allocation and risk budgeting.
Decision Flow Example
flowchart TD
S[New Trade Setup] --> A{ATR Rising?}
A -->|Yes| B[Expect Volatility: Consider Breakout or Trend Trade]
A -->|No| C{ATR Falling?}
C -->|Yes| D[Expect Consolidation: Use Tighter Stops or Wait]
C -->|No| E[ATR Stable: Use Standard Strategy]
Comparison: ATR vs. Other Volatility Indicators
| Indicator | Measures | Output | Best For |
|---|---|---|---|
| ATR | Absolute price range | Price units | Stop-losses, volatility regime |
| Bollinger Bands | Standard deviation | Bands around price | Overbought/oversold, breakouts |
| VIX | Implied volatility (S&P 500) | Percent | Macro risk, cross-asset signals |
| Historical Volatility | Std. dev. of returns | Percent | Option pricing, risk models |
- ATR is unique in using absolute price moves, making it robust for assets with different price levels (e.g., stocks vs. crypto).
- Bollinger Bands and Historical Volatility are more sensitive to outliers and are expressed in percent terms.
- VIX is a market-wide measure, not asset-specific.
Practical Example
Suppose you have the following daily prices:
- Day 1: High = 45, Close = $48
- Day 2: High = 46, Close = $50
- Day 3: High = 49, Close = $51
Step 1: Calculate TR for Day 2:
- High - Low = 46 = $6
- |High - Previous Close| = |48| = $4
- |Low - Previous Close| = |48| = $2
- TR = max(6, 4, 2) = $6
Step 2: Calculate ATR (3-day simple average):
- TR Day 1: $5
- TR Day 2: $6
- TR Day 3: $4
- ATR = (5 + 6 + 4) / 3 = $5
| Day | High | Low | Close | TR | ATR |
|---|---|---|---|---|---|
| 1 | 50 | 45 | 48 | 5 | 5 |
| 2 | 52 | 46 | 50 | 6 | 5.5 |
| 3 | 53 | 49 | 51 | 4 | 5 |
ATR Calculation Flow
flowchart TD
P[Price Data] --> Q[Compute TR]
Q --> R[Apply Moving Average]
R --> S[Get ATR]
Advantages and Limitations
Advantages:
- Provides a clear, objective measure of volatility (Investopedia)
- Adapts to changing market conditions
- Useful for risk management and trade sizing
- Works across all asset classes and timeframes
Limitations:
- Lagging indicator—reacts to past price moves (Binance Academy)
- Does not indicate trend direction, only volatility
- Needs period adjustment for different assets or strategies
- Not predictive—should be combined with other tools for entries/exits
References and Further Reading
- Investopedia: Average True Range (ATR)
- Binance Academy: ATR Indicator
- Fidelity: ATR in Trading
- CME Group: ATR and Volatility
- TradingView: ATR Indicator
Glossary
- Volatility: The degree of variation in price over time
- True Range (TR): The greatest of three price ranges for a period
- Moving Average: A smoothing technique to reduce noise in data
- Breakout: A price move outside a defined range, often with increased volatility
- Stop-Loss: An order to sell an asset when it reaches a certain price, used to limit losses
- Position Sizing: Adjusting trade size based on risk and volatility
For best results, use ATR alongside trend and momentum indicators, and always backtest your strategy before live trading.
Indicator Assessment
---
config:
xyChart:
width: 600
height: 400
themeVariables:
xyChart:
plotColorPalette: "#27ae60, #e74c3c"
---
xychart-beta horizontal
title "ATR Indicator Assessment (Scale: 1-10)"
x-axis ["Popularity", "Reliability", "Complexity", "Versatility", "Recent Interest"]
y-axis "Score" 0 --> 10
bar [9, 8, 2, 9, 7]
bar [8, 8, 2, 9, 8]
Legend: First bar (green) = Equities/Forex | Second bar (red) = Cryptocurrency
Dimension Explanations
| Dimension | Equities/Forex | Crypto | Rationale |
|---|---|---|---|
| Popularity | 9 | 8 | One of the most cited volatility indicators; developed by J. Welles Wilder (same author as RSI). Standard on virtually all charting platforms. Widely adopted in crypto for position sizing. |
| Reliability | 8 | 8 | Excellent for measuring realized volatility. Non-directional, so it provides objective volatility readings regardless of trend. Equally reliable in 24/7 crypto markets. |
| Complexity | 2 | 2 | Simple three-component formula with straightforward interpretation. Higher ATR = more volatility. One of the easiest indicators to understand. |
| Versatility | 9 | 9 | Universal applicability: stop-loss placement, position sizing, breakout detection, volatility regime identification. Works across all timeframes and asset classes. |
| Recent Interest | 7 | 8 | Consistent strong interest in traditional markets. Growing adoption in crypto for risk management and automated trading systems. Featured in many algorithmic strategies. |