Hi,
i would like to learn how to code a MTF indicator that works in an unconventional way.
Let's take for example an indicator that draws a histogram based on a simple rule.
Blue histogram bar when RSI > 50, red histogram bar when RSI < 50
We are working on M1 with the MTF indicator set to M5
A common MTF indicator would work like this:
1) 8:01 M5 RSI > 50 -> 1 Blue histo bar
2) 8:02 M5 RSI > 50 -> 2 Blue histo bars
3) 8:03 M5 RSI < 50 -> 3 Red histo bars
4) 8:04 M5 RSI < 50 -> 4 Red histo bars
5) 8:05 M5 RSI > 50 -> 5 Blue histo bars
All 5 histo bars are blue because M5 because RSI was > 50 when M5 candle closed.
I want the MTF indicator not to repaint when the M5 candle closes.
This way i would have:
1) Blue histo bar at 8:01
2) Blue histo bar at 8:02
3) Red histo bar at 8:03
4) Red histo bar at 8:04
5) Blue histo bar at 8:05
So 5 bars of different colors accordingly to the M5 RSI situation at the time the n M1 candle closed.
I will attach a QQE MTF indicator to use as example.
I hope somebody can help me.
Thank you,
Elmore
i would like to learn how to code a MTF indicator that works in an unconventional way.
Let's take for example an indicator that draws a histogram based on a simple rule.
Blue histogram bar when RSI > 50, red histogram bar when RSI < 50
We are working on M1 with the MTF indicator set to M5
A common MTF indicator would work like this:
1) 8:01 M5 RSI > 50 -> 1 Blue histo bar
2) 8:02 M5 RSI > 50 -> 2 Blue histo bars
3) 8:03 M5 RSI < 50 -> 3 Red histo bars
4) 8:04 M5 RSI < 50 -> 4 Red histo bars
5) 8:05 M5 RSI > 50 -> 5 Blue histo bars
All 5 histo bars are blue because M5 because RSI was > 50 when M5 candle closed.
I want the MTF indicator not to repaint when the M5 candle closes.
This way i would have:
1) Blue histo bar at 8:01
2) Blue histo bar at 8:02
3) Red histo bar at 8:03
4) Red histo bar at 8:04
5) Blue histo bar at 8:05
So 5 bars of different colors accordingly to the M5 RSI situation at the time the n M1 candle closed.
I will attach a QQE MTF indicator to use as example.
I hope somebody can help me.
Thank you,
Elmore
Attached File(s)
#MTF_QQEA_Hist_Alert.mq4
7 KB
|
168 downloads