MT5 indicators← Daily Range Levels 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

Daily Range Levels

Averages the ranges of completed trading days and draws lines from the current day's high and low, the open or the previous day's close as the base point. The average range is fixed during that day, but how the lines move depends on the choice of base point.

Indicator name: Daily Range LevelsMetaTrader 5Main chart

Read the range being averaged and the base point where the lines are placed separately

Averages the ranges of completed trading daysAverage range × multiplier = wDraws by adding w to and subtracting it from the base pointIf the current day's high and low are the base, the lines are also updated
Schematic diagram of how to read it. This is not an actual terminal screen.
1

Average the ranges of past daysThe default is the simple average of True Range over the previous 10 trading days.

2

Add and subtract the range at the base pointBy default, the range is added to the current day's low and subtracted from the current day's high.

3

Check whether the lines are fixed or moveWith the current day's high and low as the base, the lines move as the high and low are updated. With the open or the previous day's close as the base, they are fixed within the same day.

MT5 onlyDefault is 10 trading daysRange and base are selectable
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
Trading days to average
InpDays
10 → 14
Base of the lines
InpBase
Today's Low and High → Previous Close
Trading day start, hour
InpSessionStartHour
0 → 22

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 settingsInpDays = 10 / InpBase = Today's Low and High / InpSessionStartHour = 0
Daily Range Levels default settings
Default: ATR, 10 days, the current day's high and low as base points, start 00:00. When the current day's extremes are updated, the lines also move. The dotted lines are the previous day's high and low plus or minus today's average range.
View the screen in detail at full size
Daily Range Levels default settings (full size)
Example of changed settingsInpDays = 14 / InpBase = Previous Close / InpSessionStartHour = 22
Daily Range Levels example of changed settings
Changed example: Days is changed from 10 to 14, Base to Previous Close, and the start hour from 0 to 22. Everything else remains at the default. The base becomes the previous day's close, and the lines within the same trading day are fixed.
View the screen in detail at full size
Daily Range Levels example of changed settings (full size)

Example shown: 1-hour timeframe (H1). This is an example to explain the display. The changed settings are not recommended values. Details can be checked in the full-size view. Also check the price scale of the main chart and the positions of the candlesticks.

2

How to read it in 30 seconds

The range is in price units

The average range is a price difference, not a count of points or pips. It is used multiplied by the multiplier.

Read the base of the lines

There are 3 modes: the current day's high and low, the current day's open, and the previous day's close. The meaning of the lines differs by mode.

Note the top and bottom names

With the default, Top and Bottom can swap positions when the range becomes large.

3

What it measures

Displays the past average range from the selected price as the base point. It is not a target price or an order instruction.

ATR (True Range)

Takes the simple average, over the specified number of days, of True Range, which includes the gap from the previous close. It is not Wilder's recursive smoothing.

High-Low

Takes the simple average of each trading day's high − low over the specified number of days. The gap from the previous close is not added.

Composite 1/5/10/20

Builds 4 High-Low averages over the previous 1, 5, 10 and 20 trading days and uses their simple average. The Days value is not used in the calculation of this mode.

Base point and multiplier

Uses w=A×m, the average range A multiplied by the multiplier m. If the averaging source is the same, A is the same even when the base point is changed.

4

Situations for reading the display

The current day's low went down

Indicator
The default greenish Top
Cross-check
Top = current day's low + w, so it goes down when the current day's low is updated.
Check
Read it as a distance from the current day's extreme, not as a fixed level.
Caution
On a forming bar where the high or low is updated, the lines also change.

Top went below Bottom

Indicator
The 2 lines based on the current day's high and low
Cross-check
Top = current day's low + w, Bottom = current day's high − w. When the current day's range exceeds 2w, top and bottom are reversed.
Check
Check the range and the base point.
Caution
The line names do not always indicate top and bottom on the screen.

The previous-day dotted lines differ from yesterday's lines

Indicator
Previous Top, Previous Bottom
Cross-check
Today's w is added to and subtracted from the previous day's high and low. They are not a saved copy of yesterday's display.
Check
Also check whether the average range changed between the previous day and today.
Caution
If the average range is the same, they can match the lines at the end of yesterday.

No dotted lines appear in the changed example

Indicator
Base=Previous Close
Cross-check
The previous-day dotted lines are shown only with Today’s Low and High.
Check
Even if Show Previous Day Lines is true, check Base.
Caution
Being hidden does not mean that the calculation has stopped.
5

Steps for checking the display

1

Check the default range and base point

Check the combination of ATR, 10 days and the current day's high and low before placing it.

2

Read the movement of Top and Bottom

Compare with the candlesticks, reading the greenish line as the current day's low + range and the reddish line as the current day's high − range.

3

Check the 3 items in the changed example

The example shown changes Days, Base and Session Start Hour. It is an example that includes the effects of all 3 items at once.

4

Compare 1 item at a time by purpose

To check the differences separately, use separate charts and change the averaging mode, the number of days, the base point and the start time 1 at a time.

6

Installation and checking the package contents

Included filePurpose / location
TRI_Daily_Range_Levels.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 7 inputs. Change them on the Inputs tab of the properties. The English display name and the input name in the code are shown together.

Average range mode

Name shown on screen
Range Average
Input name
InpAverage
Default
ATR (True Range)
Allowed range
ATR (True Range) / High-Low / Composite 1/5/10/20
Description
Selects the range including gaps, the intraday range, or the average of 4 lengths.

Trading days to average

Name shown on screen
Days
Input name
InpDays
Default
10
Allowed range
1〜100
Description
Used with ATR and High-Low. In Composite it is not used in the calculation, but the allowed-range check is still performed.

Base of the lines

Name shown on screen
Base
Input name
InpBase
Default
Today's Low and High
Allowed range
Today’s Low and High / Today’s Open / Previous Close
Description
The default is the current day's low + w and high − w. With the open or the previous day's close, w is placed above and below that price.

Average range multiplier

Name shown on screen
Range Multiplier
Input name
InpMultiplier
Default
1
Allowed range
0.1〜10.0
Description
The value multiplied by the average range. The default is 1.

Lines using the previous day's high and low

Name shown on screen
Show Previous Day Lines
Input name
InpShowPrevious
Default
true
Allowed range
true / false
Description
Takes effect only with Today’s Low and High. Today's range is added to and subtracted from the previous day's high and low.

Trading day start, hour

Name shown on screen
Session Start Hour
Input name
InpSessionStartHour
Default
0
Allowed range
0〜23
Description
Server time. Combined with the minute. There is no automatic adjustment for daylight saving time. On the daily timeframe, only 00:00 can be used.

Trading day start, minute

Name shown on screen
Session Start Minute
Input name
InpSessionStartMinute
Default
0
Allowed range
0〜59
Description
Specifies the start time. If there is no bar at the specified time, the split starts from the bar that comes after that time has passed.
8

Usage specifications

Usable timeframes

Use it on daily and lower timeframes; on daily charts the start time is only 00:00. It does not start on weekly or monthly charts.

Trading days built from the chart's bars

It is not a product that loads and copies the broker's D1. It groups days from the bars of the currently open chart and the server time. If the start is before noon, the day is named after the start date; if at or after noon, it is named after the following day. The start time does not shift automatically for daylight saving time.

Weekend bars and 00:00 / 07:30

Bars that would be named Saturday or Sunday are included in the preceding trading day (usually Friday). With start 00:00, Saturday and Sunday bars are included there. With start 07:30, Monday 00:00–07:29 is also usually included in the preceding Friday trading day, and from Monday 07:30 onward it is Monday.

Start 22:00 and Sunday bars

With start 22:00, the day is named after the following day, so bars from Sunday 22:00 onward are Monday. Bars from Friday 22:00 onward and Saturday bars are included in the preceding Friday. If there are no Sunday bars, the span from the first Monday bar until Monday 22:00 becomes a short Monday trading day.

Holidays are not filled with a fictitious 1 day

Days without bars are not filled in. For example, with start 22:00, even if Monday is a market holiday, bars from Sunday 22:00 onward alone create a short Monday. That short day is also used in the next day's calculation. On charts with missing bars or different holidays, the number of days and the values change.

Combinations of timeframe and start time

On a chart where 4-hour bars start at 00, 04, 08, 12, 16 and 20 o'clock, if you specify start 22:00, the first bar representing the boundary is the next 00:00 bar. No new 22:00 bar is created. The rules for the start time and trading day names remain unchanged.

Diagonal lines connecting steps

At a boundary where the level switches, a diagonal segment connects the previous bar and the next bar. This does not mean there is another calculated level partway along it.

Recalculation due to history and settings

Past lines are also recalculated when history is added or corrected or settings change. It is not guaranteed that past displays remain unchanged under all conditions.

When a line is off screen

This product does not widen the chart's vertical scale to fit distant lines. If a line is not visible, check not only display ON/OFF but also the price scale and display range.

Average range and the current day's movement

The average is calculated using only completed trading days, so it does not change during the day. However, lines based on the current day's high and low move if the forming high or low changes.

Initial values and display OFF

If the number of days needed initially is not available, nothing is drawn. Average Range is a data value that is not drawn as a line. Even when the previous day's lines are set to display OFF, their calculated values are kept.

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

The first line does not appear

The first trading day is excluded because it may have started partway through. With N days, drawing starts from the N+2nd trading day (the 12th with the default 10). Composite starts from the 22nd. This differs from the calendar day count that includes holidays.

The values differ from MT5's ATR

This product builds trading days from the chart's bars. If the timeframe, the start time, weekend bars or the history initialization differ, the values do not match the standard ATR even with the same number of days. It is not a product that gives the same values as the standard under all conditions.

Cannot start

Check the input ranges and the timeframe. If startup is refused, the reason appears as 1 line in English on the MT5 Experts tab. No panel with the reason appears on the chart. The allowed-range check is also performed for numeric inputs of the mode that is not in use.

The values are not the same as on another chart

Check with the timeframe, the start position of the history, the start time, weekend bars and holidays aligned. Having the same date alone does not necessarily mean that the bars included in the calculation are the same.

Lines and candlesticks overlap

This display overlays price levels. Overlaps or crossings are not instructions for a reversal, a continuation or an order.

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

True Range and initial value

The normal TR is max(current day's high, previous trading day's close) − min(current day's low, previous trading day's close). Only the TR of the first complete trading day used starts as high − low, and the close of the excluded first day is not used. The simple average of the TR over the past N days is A in ATR mode.

The 3 averaging modes

High-Low is the average of (H−L) over the past N days. Composite adds the (H−L) averages over the previous 1, 5, 10 and 20 days and divides by 4. In Composite, the Days setting has no effect on the calculation.

Line calculation

w=A×Range Multiplier. In the current day's high and low mode, Top=current day's low+w and Bottom=current day's high−w. In the open mode, Top=current day's open+w and Bottom=current day's open−w. In the previous close mode, Top=previous day's close+w and Bottom=previous day's close−w.

Previous-day lines

In the current day's high and low mode, Previous Top=previous day's low+today's w and Previous Bottom=previous day's high−today's w. They do not use the previous day's range. Other base modes do not draw these 2 lines.

Colors and line overlaps

Top is SeaGreen and Bottom is Crimson. The previous-day lines are MediumSeaGreen and IndianRed dotted lines. In the current day's high and low mode, when the current day's range=w, Top overlaps the current day's high and Bottom the current day's low. If the current day's range>2w, Top goes below Bottom.