Multi Timeframe Indicators - page 1226

 
Mladen Rakic #:

Histo multi time frame version with alerts and arrows attached

Also a multi time frame of regular version attached (alerts in it too)

Hi Mr Mladen.

can you convert these indicators to the mt5 version?


HalfTrend MTF with alerts.mq4  
HalfTrend 2 histov arrows.mq4
 

Forum on trading, automated trading systems and testing trading strategies

All About Price Action

Sergey Golubev, 2025.11.26 07:35

Price Action Analysis Toolkit Development (Part 52): Master Market Structure with Multi-Timeframe Visual Analysis

Price Action Analysis Toolkit Development (Part 52): Master Market Structure with Multi-Timeframe Visual Analysis

Multi‑timeframe analysis has long been a core method for traders who want a more profound understanding of market direction. A signal that looks strong on a lower timeframe can quickly lose appeal when viewed against the trend of a higher one. Many traders have experienced an M15 setup that fails because H1 or H4 are moving in the opposite direction. Confirming alignment across multiple time horizons often makes the difference between a trade that works and one that fails. In trading circles, the topic has been explored in various ways. Some approaches rely on numeric comparisons and calculated statistics, while others present symbolic indicators or trend readings. My own published works have also touched on multi‑timeframe confirmation, using different logical angles in each case. The Timeframe Visual Analyzer( the expert advisor I am introducing), builds on that collective foundation, taking a fresh route by turning those relationships between timeframes into something visually clear and interactive.

 
Use the CODE button (Alt-S) when inserting code.

A moderator corrected the formatting this time. Please format code properly in future; posts with improperly formatted code may be removed.

When you call indicators from a higher timeframe, it’s important to remember that the higher TF only updates on a **new bar**, not every tick. If you don’t handle that, the MTF indicator can look like it’s “lagging” or giving strange values.

In MQL4/MQL5 I usually do two things:

1) Always pass the timeframe explicitly when I use iCustom / iMA / iRSI, etc. For example:

iRSI(_Symbol, PERIOD_H1, 14, PRICE_CLOSE, shift);

2) In the calling code I only recalculate the logic when a new bar appears on the **higher timeframe**, something like:

   static datetime lastTime = 0;
   datetime htTime = iTime(_Symbol, PERIOD_H1, 0);
   if(htTime != lastTime)
   {
      lastTime = htTime;
      // update the MTF values here
   }
This way the indicator updates exactly when the higher timeframe candle closes, which is usually what we want for MTF signals.

Maybe this will help someone who is trying to convert a normal indicator into an MTF version and wondering why the values change in a strange way.