Check the timeframe
Attach it to a chart with a timeframe shorter than 1 day. The date is server time, not the PC clock.
Uses the number of bars counted from the first bar of the server date as the calculation period of each bar.
PeriodIt is 1 on the first bar of the day and 2 on the next bar, and keeps increasing. The oldest day is counted from the first loaded bar.
Blue main lineThe calculated value of the base selected from 6 types.
Orange AverageOnly RVI and Stochastic have it. It is not a simple average of the drawn blue line.
Compares the default settings and a settings change example on a screen with only this product applied.
Published example: M1. This is an example to explain the display. The example with changed settings is not a set of recommended values. Details can be checked in the actual-size view. Also check the vertical axis and units of the separate window. Except for products with a fixed scale, the scale changes with the settings and the displayed range.
Attach it to a chart with a timeframe shorter than 1 day. The date is server time, not the PC clock.
The default is %R. The scale and center line change with the type.
The oldest day is affected by where loading starts and has sections without a line.
It is not a fixed-period line. The period increases on each bar and the count restarts when the date changes.
The bars that actually exist on the chart are counted for each server date. Hours without bars are not counted, and for the oldest day the first loaded bar is counted as 1 even if that day starts partway through.
%R is the position of the close within the day's high and low so far. CCI is the deviation from the average of the day's closes so far.
The calculation period is the intraday bar count, but part of the calculation also refers to bars of the previous day. The value is not necessarily decided by the day's bars alone.
Uses the intraday bar count as the period and calculates the smoothing for each period from the first loaded bar. The smoothing is not reset each day.
D1 and higher are not supported. First show the default %R.
Tell the position where the date changes apart from hours without bars.
Change the Oscillator Base input, and check the colors, center line and scale.
The oldest day may start partway. With RSI, the effect of the starting point extends to later days as well.
| Included file | Purpose / location |
|---|---|
| TRI_Day_Anchored_Oscillator.ex5 | The 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.
Extract the ex5 main file rather than leaving it in the compressed file.
In MT5, open MQL5/Indicators from 'File → Open Data Folder' and place the included ex5 there.
Refresh the Navigator or restart MT5, and apply it to the target chart. Place only 1 instance of the same product on 1 chart.
First check with the default values. Changes and removal are done from the chart's 'Indicators List'.
Using this product does not require allowing DLLs. When removed, this product's drawings are cleared.
There is 1 input. Change it on the Inputs tab of the properties. The English item name and input name defined in the source are shown together.
InpBaseIf the history starts partway through a day, the oldest day is counted from the first loaded bar rather than from the actual start of the day. The %R, CCI and DeMarker values for that day may differ from those with a longer history.
From the next day, %R, CCI and DeMarker are calculated with the required bars within the day. RSI depends on where the smoothing starts, so the effect remains on later days as well. This does not mean that new bars being added later in itself changes past values.
The latest value changes during the bar. There are no notifications or marks.
At the beginning of the day the period is short, so values may lean toward the edges or change more easily. They do not necessarily always move widely.
RSI is designed to trace back through history for each period. With long history and short timeframes, the initial processing may take time, so use it within the range you need.
This manual describes adding 1 instance of this product to 1 chart. To compare different settings, use separate charts.
The display is a record of calculation results. It does not direct trading decisions and does not guarantee future price movements.
Daily and longer timeframes cannot be started. Switch to a timeframe shorter than 1 day, and also check the English diagnostic message in the Experts tab.
On the oldest day, the required earlier bars or close-to-close changes are not available. If the oldest day is short, the empty line may continue into the next day as well.
These are the defined values when the calculated range is 0. However, that value does not necessarily mean the range is 0.
Changing the base changes the scale. The center is −50 for %R, 0 for CCI and RVI, 0.5 for DeMarker, and 50 for Stochastic and RSI.
Only RVI and Stochastic have an Average. Even for these 2, it is not displayed until the required history is available.
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.
%R = (close − intraday lowest low) ÷ (intraday highest high − intraday lowest low) × 100 − 100. If the range is 0, it is 0. CCI uses the mean of the intraday closes and the mean absolute deviation; a flat window gives 0. DeMarker uses the intraday averages of the upward moves of the highs and the downward moves of the lows; if both are 0, it is 0.5.
RVI applies weights of 1, 2, 2, 1 to close − open and to high − low, sums them over the intraday period, and takes the ratio. If the denominator is 0, it is 0. Stochastic sums the numerator and the range built with the current period over the latest 3 bars and takes the ratio × 100; if the denominator is 0, it is 100.
For RVI, the current bar and the previous 3 bars are recalculated with the same period as the current bar and averaged with weights 1, 2, 2, 1. For Stochastic, the current bar and the previous 2 bars are recalculated with the same period and simply averaged. It is not an average of the points of the drawn main line.
For each period p, the averages of the upward and downward moves are built from the first p close-to-close changes, and are then smoothed as (previous average × (p − 1) + current change) ÷ p. If the downward average is 0 and there is an upward move, it is 100; if both are 0, it is 50.
Number the oldest bar 0, and let f be the number of the first bar of the day. The RVI main line requires f ≥ 3 and its Average f ≥ 6. The Stochastic main line requires f ≥ 2 and its Average f ≥ 4. RSI has a value only when the bar number is at least that bar's period. The oldest day does not meet these conditions.
Blue is the main line and orange is Average. The dotted line is a guide to the center of each base. The vertical axis is automatic. The displayed digits are 3 for DeMarker, 4 for RVI and 2 for the others. Do not tell a bar without a value from a calculated 0 by the header alone; also check the line and the required history.