# ATR-Based Quantity and Risk

The Average True Range (ATR) study takes the moving average of the true range over the specified period.

Definitions:

• True Range = True High - True Low
• True High = The greater of the current bar's high or the previous bar's close
• True Low = The lesser of the current bar's low or the previous bar's close

If we put the ATR into the toolbox and apply the PriceToDollar function to it, it will give us the same information, but converted into price instead of points.

Formula:

`PriceToDollar( ATR(@,Sim,10))`

(Note: PriceToDollar converts points into the currency in which the contract is traded)

On this thirty-minute DAX chart, the ATR is 13.3 points multiplied by €25 per point resulting in €332.50. In a trading system environment, where you probably have to wait for the next event and/or signal, it would be fair to say that there is an "implied risk" of €332.50 (on average) in any of the bars. Let's assume you are willing to risk €5,000 per trade. Using this risk measurement, you can take €5,000 divided by €332.50 for 15.04 contracts per trade. Inside the toolbox, you can use the floor function to always round that value down to the nearest integer.

Formula:

`Floor(5000/ PriceToDollar( ATR(@,Sim,10)))`

With this formula, we can use the ATR to determine how many contracts we want to trade at any point in time. If volatility increases and the markets move faster, the bars will have a wider range. Therefore, the implied risk increases and the formula would give us less contracts to trade.

This can also be used to determine the right time frame and/or market to trade. Following the \$5,000 and the ATR rule, I could possibly choose not to trade (or to trade with just one lot) the pit-traded S&P on a daily chart.

A smaller time frame or the E-mini S&P, which is one-fifth the size of the pit-traded S&P, would work.

This can also be used for equities.

On a sixty-minute Facebook chart, the "implied risk" following the ATR method is around 42 cents. Opening a trade with \$5,000 risk would give us the opportunity to buy or sell 11,876 Facebook shares.