MT5 indicators← ATR Ratio product page日本語の取扱説明書

This product is in preparation for release. Product files are not yet distributed; the manual is published so that you can review its content. This manual is an English translation of the Japanese manual. Images (screens and figures) are not translated and may contain Japanese text or earlier names.

For Trilogy users

ATR Ratio

Divides a short-period ATR by a long-period ATR and shows with a blue line how many times the recent price range is relative to the long-term average. If needed, an average line of the ratio can be added.

Indicator name: ATR RatioMetaTrader 5Separate window

Short-term average range ÷ long-term average range

Short-term ATR ÷ long-term ATR → blue ratioAbove 1: short term is larger / below: smallerOptional average line and reference levelIn a calculation window where the long-term ATR is 0, the ratio is drawn as 1
Schematic diagram of how to read it. This is not an actual terminal screen.
1

Above 1The short-term ATR is larger than the long-term ATR.

2

Below 1The short-term ATR is smaller than the long-term ATR.

3

Exactly 1Set to 1 when the 2 are equal, and also when the long-term range is 0.

A unitless ratio, not priceMA is hidden by defaultThe reference line is not used in the calculation
1

MT5 display and examples of changed settings

Compares the default settings and a settings change example on a screen with only this product applied.

Settings change example: these items are changed
Short-term ATR period
InpFastPeriod
7 → 14
Long-term ATR period
InpSlowPeriod
49 → 28
Ratio average period
InpMAPeriod
0 → 9

All other inputs remain at their defaults. On a PC, the default is on the left and the change example on the right; at smartphone width they appear in the same order from top to bottom.

Default settingsInpFastPeriod = 7 / InpSlowPeriod = 49 / InpMAPeriod = 0
ATR Ratio default settings
The 7/49 ratio is shown as a blue line, and 1.0 as a gray dotted line. The 2nd 0.0000 in the header is the field for the hidden Ratio MA.
View the screen in detail at full size
ATR Ratio default settings (full size)
Settings change exampleInpFastPeriod = 14 / InpSlowPeriod = 28 / InpMAPeriod = 9
ATR Ratio settings change example
Changed to 14/28, and an SMA 9 of the ratio is added as an orange-red line. The vertical axis differs for each image.
View the screen in detail at full size
ATR Ratio settings change example (full size)

Example shown: 1-minute chart (M1). This is an example to explain the display. The settings change example is not a recommended value. Details can be checked in the full-size view. The vertical axis of the separate window is adjusted automatically for each image, so do not compare values by on-screen height alone.

2

How to read it in 30 seconds

Blue

Short-term ATR ÷ long-term ATR.

Gray dotted line

The reference level specified with Reference Level.

Orange-red

Setting Ratio MA Period to 1 or more shows the average of the ratio.

3

What it measures

Read the relative size of the price range, separately from direction.

Short term and long term

Both ATRs are simple averages of TR. Make Fast shorter than Slow.

Reference 1

The value when the short-term and long-term ATRs are equal. However, 1 is also assigned when the long-term ATR is 0.

Average of the ratio

Ratio MA is a line that further averages the blue ratio.

Level lines

Changing Reference Level does not change the calculation of the ratio or its average.

4

Situations for reading the display

The ratio has exceeded 1

Indicator
The short-term average range exceeds the long-term one.
Cross-check
Also check the actual range on the price chart.
Check
Compare with other points in time using the same periods.
Caution
It does not show a rise or fall in price.

The ratio stays at 1

Indicator
The 2 averages may be equal, or the long-term ATR may be 0.
Cross-check
Check the price range.
Check
Distinguish a section with no movement from one where the average ranges are about the same.
Caution
The ratio alone cannot distinguish the 2 cases.
5

Steps for checking the display

1

View with the default 7/49

Check the blue ratio and the 1.0 reference line.

2

Add the average line

Set Ratio MA Period to 1 or more and select the method.

3

Keep the comparison conditions

Even when the value becomes larger, do not read it as price direction.

6

Installation and checking the package contents

Included filePurpose / location
TRI_ATR_Ratio.ex5The MT5 main file. Place it in MQL5/Indicators.

The ZIP contains only 1 item, the main file. The manual is opened from the product page on the site. Source code is not included. MT5 only; registration, account authentication and placing a license file are not required. Use it without changing the file name.

1

Extract the ZIP

Extract the ex5 main file rather than leaving it in the compressed file.

2

Open the data folder

In MT5, open MQL5/Indicators from 'File → Open Data Folder' and place the included ex5 there.

3

Apply this product

Refresh the Navigator or restart MT5, and apply it to the target chart. Place only 1 instance of the same product on 1 chart.

4

Check the settings and display

First check with the default values. Changes and removal are done from the chart's 'Indicators List'.

This product does not require DLL permission or enabling automated trading. When removed, this product's drawings are cleared.

7

Settings

There are 5 inputs. Change them on the Inputs tab of the properties. The English display name and the input name in the code are shown together.

Short-term ATR period

Name shown on screen
Fast ATR Period
Input name
InpFastPeriod
Default
7
Allowed range
1–999 bars, smaller than Slow
Description
Numerator of the ratio.

Long-term ATR period

Name shown on screen
Slow ATR Period
Input name
InpSlowPeriod
Default
49
Allowed range
2 to 1000 bars, larger than Fast
Description
Denominator of the ratio.

Ratio average period

Name shown on screen
Ratio MA Period
Input name
InpMAPeriod
Default
0
Allowed range
0–500 bars
Description
0 hides Ratio MA.

Ratio average method

Name shown on screen
Ratio MA Method
Input name
InpMAMethod
Default
Simple (SMA)
Allowed range
SMA / EMA / SMMA / LWMA
Description
Averaging method applied to the ratio.

Reference level

Name shown on screen
Reference Level
Input name
InpLevel
Default
1
Allowed range
0〜10
Description
Position of the gray dotted line. Default 1.0. It does not affect the ratio calculation.
8

Usage specifications

Forming bar

Values and drawing change with the latest bar's high, low and close. They are also recalculated when history is added or corrected or settings change.

Conditions for comparison

Compare with the same symbol, timeframe, period and loaded history. The display is not a forecast of future prices.

Starting position

The ratio starts from bar Slow. Ratio MA starts at the same time with EMA, and otherwise MA period − 1 bars later. By default, the ratio is displayed from the 49th bar.

Hidden fields

The 2nd 0.0000 in the default header does not mean Ratio MA is 0. First check whether the line is set to hidden.

Only 1 instance of the same product on 1 chart

This manual describes adding 1 instance of this product to 1 chart. To compare different settings, use separate charts.

For on-screen display only

This product shows calculation results through plot buffers and does not place orders. It does not guarantee profit or future price movement.

9

Troubleshooting and usage notes

Does not start after entering Fast and Slow

Fast<Slow must be satisfied. The same period cannot be used either.

No orange-red line

Ratio MA Period is 0 by default. Showing it requires 1 or more and the necessary history.

Nothing is shown after entering inputs

Check the allowed range of the inputs and the number of history bars. Outside the range, the indicator does not start, and the reason is shown in English in the Experts tab of the Toolbox. No explanation is shown on the chart.

If the first display does not appear, check history loading and the input ranges. If an earlier display has stopped updating, first check the price feed and the terminal's connection status.

10

Technical information and specification details

Ratio formula and range

R=ATR_fast/ATR_slow. If the denominator is 0, R=1. Because TR is non-negative, the calculated range is 0 to Slow/Fast (0 to 7 by default). Floating-point rounding does occur.

Averaging and display

SMA, EMA, SMMA and LWMA can be used. The SMMA seed is the simple average of the ratio over the first MA period. The display shows 4 digits.

Relationship with ATR

The internal ATR is a simple average of TR, but this does not mean that the whole product, including the ratio and the average line, has the same values as the standard ATR.