Indicators - amplitude of the latest X bars

MQL5 指标

指定


create two indicators with same logic but different visualizations

the logic is 
identify if the last bar has the highest or lowest amplitude compared to the latest X bars
amplitude can be ( open and close / high and low )
X is a input value, is the numbers of bars to compare (10 = ten bars back; 50 = fifty bars back)

visualization 1
if bar is the highest amplitude and is an up bar, then indicator is (1)
if bar is the highest amplitude and is a down bar, then indicator is (-1)

visualization 2
plot the indicator value

反馈

1
开发者 1
等级
(555)
项目
922
48%
仲裁
300
59% / 25%
逾期
123
13%
工作中
2
开发者 2
等级
(709)
项目
1028
39%
仲裁
47
49% / 23%
逾期
84
8%
空闲
3
开发者 3
等级
(11)
项目
17
59%
仲裁
2
0% / 100%
逾期
2
12%
空闲
4
开发者 4
等级
项目
0
0%
仲裁
0
逾期
0
空闲
5
开发者 5
等级
(38)
项目
61
30%
仲裁
5
20% / 40%
逾期
0
空闲
6
开发者 6
等级
项目
0
0%
仲裁
0
逾期
0
空闲

项目信息

预算
30+ USD
开发人员
27 USD
截止日期
 1  2 天