difference between ma in 15 timeframes and ma in 5 timeframes

 

Hello everyone,

how do I get the difference between ma in 15 timeframes and ma in 5 timeframes and draw the difference in 5 min chart?

 
Ahmed Elsayed: Hello everyone, how do I get the difference between ma in 15 timeframes and ma in 5 timeframes and draw the difference in 5 min chart?

Instead of comparing an MA for M15 time-frame and another for the M5 time-frame, you can simplify things by using "equivalence" ...

Forum on trading, automated trading systems and testing trading strategies

Time Frames Moving Averages

Fernando Carreiro, 2022.11.15 11:43

Are you asking about representing the same equivalent moving average on a different time-frame?

If yes, then a MA(6) on an M10 time-frame would be equivalent to a M(8.57) on a M7 time-frame.

Forum on trading, automated trading systems and testing trading strategies

Daily TF SMA 50 and SMA 200 Values for 15Min?

Fernando Carreiro, 2016.08.22 11:23

Simple Maths!

  • D1 (day) = 24 hours = 1440 minutes.
  • M15 = 15 minutes.
  • D1/M15 = 1440/15 = 96

So to have the equivalent SMA 50 and SMA 200 on the M15 chart, you would have to use an SMA 4800 (50 x 96), and an SMA 19200 (200 x 96).

However, such BIG SMAs, will probably not be very practical and also be more CPU intensive. An alternative is to use a MTF (Multi-timeframe) Moving Average Indicator which will display the Daily SMA on the M15 chart instead. It will not be as smooth as this equivalent, but it will be the EXACT values of the daily one along the entire day.

Try both methods and see which one you prefer.

Forum on trading, automated trading systems and testing trading strategies

SOME EA's working fine on MT4 but NOT when migrated to VPS - They have Indicators with custom timeframes

Fernando Carreiro, 2022.10.07 15:08

Your don't need to generate Offline Charts for such a simple indicator as a moving average and that applies to many indicators. Just adjust the period accordingly.

Example: A SMA(20) on H2 translates to a SMA(40) on H1. It will obviously be slightly different because H1 has more resolution than H2, but will be equivalent.


Reason: