Module 4 · Lesson 7 of 12 · Volume and indicators · About 5 minutes

Bollinger Bands, Keltner Channels and ATR: Measuring Volatility

On this page
  1. What you will learn
  2. Why measure volatility at all?
  3. How are Bollinger Bands built?
  4. Volatility bands diagram
  5. How is ATR calculated?
  6. How are Keltner Channels different?
  7. What is a squeeze?
  8. What this does not tell you about volatility bands
  9. Method in Practice
  10. Check yourself
  11. Reflect on your own process
  12. Sources

Before you read: MACD Explained: Lines, Histogram and What Crosses Mean

What you will learn

Why measure volatility at all?

Would a $2 move mean the same thing in a quiet market and a wild one?

Volatility is how much price tends to move. A move that is large for a quiet market can be ordinary for a busy one. Volatility measures put moves in context, and many traders use them to size positions and set distances for stop orders. The position size lesson shows how the distance to a stop changes the size of a position for the same risk.

How are Bollinger Bands built?

If you drew lines a fixed number of standard deviations around an average, how would they behave when markets get busier?

Bollinger Bands, developed by John Bollinger, have three lines. The defaults are:

When closes spread out, the standard deviation grows and the bands widen. When closes bunch together, the bands narrow. Two related measures are bandwidth (the distance between the bands divided by the middle band) and %B (where price sits between the bands, with 0 at the lower band and 1 at the upper).

You may have read that about 95% of values in a normal distribution fall within two standard deviations of the mean. That is not a forecast about these bands. Each band is built from a recent average of closes and the spread of those closes. The next price is not a random draw from a known, fixed distribution just because the formula uses standard deviation. Even if returns were normally distributed, price levels would not follow from that. Trends, dependence between bars, estimated inputs and fat tails all matter. John Bollinger’s own published rules say to make no statistical assumptions based on the standard deviation calculation. This lesson does not establish any next-bar coverage rate or confidence interval.

Fictional hand example, deliberately length 4 for calculation rather than changing the stated 20 default: closes 98, 100, 100, 102 price units have mean 100. Using population divisor 4, the squared deviations 4+0+0+4 sum 8, variance 2, SD √2≈1.414214. At multiplier 2, the band is 100±2√2, or 97.171573–102.828427. Its width≈5.656854; normalized bandwidth≈0.05656854 (5.656854% of the middle). The last 102 close has %B=(102−97.171573)/5.656854≈0.853553. An invented next close of 110 would sit outside these bands, which were calculated before that bar. Including 110 would create a new rolling window with a new mean and standard deviation. One example cannot confirm or refute any coverage rate; it only shows which quantity was calculated.

Volatility bands diagram

Bollinger Bands narrowing and widening with an ATR panel on a fictional path. Fictional Bollinger Bands narrow during a quiet stretch and widen when moves get larger, while ATR in the lower panel rises at the same time. Illustrative diagram constructed for teaching. Not real market data.

Illustrative diagram constructed for teaching. Not real market data.

The diagram shows a fictional price path with Bollinger Bands. The bands narrow during a quiet stretch and widen when moves get larger, while the ATR panel below rises at the same time. It is constructed for teaching and is not real market data.

How is ATR calculated?

What is the full distance price traveled in a bar, including any gap from the prior close?

True range for one bar is the largest of three distances:

  1. high − low;
  2. the distance from the high to the prior close;
  3. the distance from the low to the prior close.

The second and third cover gaps: if a market opens well above yesterday’s close, the bar’s own high-low range understates how far price moved. Average true range (ATR), introduced by J. Welles Wilder, is a smoothed average of true range, usually over 14 bars. ATR is in price units and has no direction: it rises in busy markets whether prices are rising or falling.

Example. Prior close $50, today’s high $53, low $51. High − low is $2, high − prior close is $3, low − prior close is $1. True range is $3.

Try it on a chart

  1. Find the Bollinger Bands on the price and the ATR panel below it.
  2. Find a stretch where the bands narrow and check what ATR did at the same time.

TradingView Advanced Real-Time Chart

TradingView chart. Showing it connects your browser to TradingView, which may set cookies or store settings and similar identifiers in your browser.

Privacy details

Charts and quotes are TradingView's data, not ours, and may be delayed.

Open the full practice chart

How are Keltner Channels different?

What changes if the band width comes from ATR instead of standard deviation?

A Keltner Channel draws bands a multiple of ATR around an exponential moving average, commonly a 20-period EMA with bands 1.5 or 2 ATRs away. Their width inputs differ: ATR uses bar ranges/gaps while close-based standard deviation uses dispersion of closes. Relative smoothness depends on lengths, smoothing and the price path; there is no universal guarantee that one channel is smoother under every configuration.

What is a squeeze?

What happens to the bands when a market goes quiet for a while?

A squeeze is a period when Bollinger Bands narrow. John Bollinger’s published rules use BandWidth to identify it. Some traders instead define it as the Bollinger Bands moving inside a Keltner Channel. These definitions need not agree, so state which one you use. A squeeze describes low recent volatility. It does not say when volatility will expand or in which direction, and this lesson measures no frequency of later expansion.

What this does not tell you about volatility bands

  • A touch of a band is not a sign that price will reverse or continue. In strong trends, price can ride along a band for a long time.
  • Volatility measures look backward. They do not tell you how much the next bar will move.
  • A squeeze does not show the direction of any later move.
  • Nothing here is a signal to buy or sell.

Method in Practice: ATR sets the distance, and the size

Fictional example. John, Harbor Index futures, the prices, times, costs and results are all invented for teaching. This shows how a written plan can be built and tested. It is not a recommendation, and nothing here says how often this idea works.

Try it on a real chart. Look at the chart in this lesson, then test this idea yourself on past sessions with bar replay. Keep your own count, including the days with no trade.

The idea. ATR measures how far price has typically moved per bar recently. John uses it for two numbers in his plan: how far away his "wrong if" sits, and so how many contracts fit inside his $150 cap. Same entry rule, three days with different ATR, and three different sizes, including zero.

John's plan

Setup
opening range high (08:30–09:00), marked at 09:00
Enter if
a 5-minute bar closes above the opening range high. Buy.
Wrong if
price trades 1.5 ATR(14, 5-minute) below the entry (stop order)
Manage
take half at entry + 1.5 ATR, the rest at entry + 3 ATR or by 14:30
Risk
$150 maximum, costs included. Contracts = $150 ÷ the cost per contract, rounded down

Three outcomes

  • Worked: ATR 0.30, so 2 contracts → +$125

  • Failed: ATR 0.60, so only 1 contract, stopped out → −$100, inside the limit

  • No trade: ATR 1.10. One contract would cost $175, more than the cap, so 0 contracts → $0

Show the full replays
ItemPlan
ContextOpening range 08:30–09:00
Entry conditionA 5-minute bar closes above the opening range high. Buy at market after that close
Wrong ifA stop order 1.5 × ATR(14, 5-minute, read at the entry bar's close) below the entry fill, rounded down to a tick
Management2 contracts: half at entry + 1.5 ATR (limit), stop for the rest moves to the entry price, rest at entry + 3 ATR (limit). 1 contract: all at entry + 1.5 ATR. Time limit 14:30 CT
Risk cap and size$150. Cost per contract = (entry − stop + 1 tick of slippage) × $100 + $5. Contracts = $150 ÷ cost, rounded down, at most 2
Not trading ifScheduled major release within the hour, size works out to 0, or no setup by 12:00 CT

Replay A: worked (ATR 0.30)

Time (CT)What happenedJohn
09:15–09:20Closes 100.95 above the opening range high. ATR 0.30Filled 101.00. Stop 101.00 − 0.45 = 100.55. Cost (0.45 + 0.05) × $100 + $5 = $55, so 2 contracts
09:20–10:30Trades 101.45 (+1.5 ATR)Sells 1 at 101.45 (limit). Stop for the other moves to 101.00
10:30–12:20Trades 101.90 (+3 ATR)Sells the last 1 at 101.90 (limit)

Result after costs: +0.45 point = +$45, +0.90 point = +$90, commissions −$10. Net +$125.

Replay B: failed (ATR 0.60)

Time (CT)What happenedJohn
09:25–09:30Closes 101.05 above the opening range high. ATR 0.60Filled 101.10. Stop 101.10 − 0.90 = 100.20. Cost $100, so 1 contract
09:30–10:20Falls through 100.20Stop triggers, filled 100.15

Result after costs: −0.95 point = −$95, commission −$5. Net −$100. Journal: "A wider day meant a wider stop and half the size. The loss stayed inside the cap because the size shrank."

Replay C: no trade (ATR 1.10)

Time (CT)What happenedJohn
09:10–09:15Closes 101.00 above the opening range high. ATR 1.10Stop would be 1.65 below. Cost $175 per contract, more than the $150 cap: 0 contracts
09:15–12:00Swings two points both waysNo trade

Result: $0. Journal: "Even one contract would break the cap. On a day like this, the honest size is zero."

Test it yourself

  • Write the ATR length, bar size and multiple first. Then work out the size by hand for three different days.
  • Replay the same entry rule on quiet and wild days. Log how often the size came out at zero.
  • Compare with a fixed stop distance at the same cap. Notice which days each version skips.

Where it breaks

  • ATR looks backward. The next bar can move much more (this lesson).
  • A stop order can fill past its price.
  • On wild days, an honest cap often means no trade at all (the no-trade replay).

Calculators: position sizerisk/rewardexpectancy

Reflection question: Does your position size change with volatility, or does your risk change instead?

Check yourself

  1. Prior close $30, high $31, low $28. What is the true range? Hint: compare all three distances.
  2. Why do Bollinger Bands widen when markets get busier? Hint: what happens to standard deviation?
  3. Why is “the next price has 95% probability of staying inside the current bands” not established merely by drawing 2 SD bands?
  4. Recompute the four-close example’s mean and variance. Would a newly included 110 leave the same window unchanged?

Reflect on your own process

For your own notes; there is no score and no right answer.

  1. If your plan uses ATR to set stop distances or size, where is that rule written and how did you test it?
  2. Which squeeze definition, if any, does your checklist use, and is it stated precisely enough for someone else to apply?
  3. When you note a band touch in your journal, what do you record so you can review it honestly later?
  4. Does your position size change with volatility, or does your risk change instead?

Sources

Last reviewed . Spotted a mistake? Report an error.