Mtf Macd Trend Color Jo

Multi-Timeframe (MTF) MACD Indicator with Color Trend Modes & Anti-Flicker

Overview

This is an optimized, high-performance Multi-Timeframe (MTF) MACD Custom Indicator for MetaTrader 5 (MQL5). It allows you to monitor MACD dynamics from higher timeframes (e.g., H1, H4, D1) directly on your lower timeframe execution chart without chart lag or repainting issues.

Key Features

  • Zero Repaint / Anti-Flicker: Includes an optional strict closed-bar calculation mode ( InpStrictClosed ). It locks higher-timeframe data to confirmed closed bars, eliminating bar-flicker on live ticks.

  • High Performance (Bulk Array Copy): Optimized memory handling using single-pass array copying outside execution loops to prevent CPU lag during backtesting or live execution.

  • Dual Color Modes: Visual confirmation of market bias via two customizable color logic methods.

  • Bilingual Support: Switchable label setups between English and Indonesian.

Input Parameters Guide

Parameter Type Default Description
InpLanguage ENUM_LANGUAGE LANG_ENGLISH Set display language ( LANG_ENGLISH or LANG_INDONESIAN ).
InpTimeframe ENUM_TIMEFRAMES PERIOD_H1 Higher target timeframe to calculate (e.g., H1, H4, D1).
InpFastEMA int 12 Fast EMA calculation period.
InpSlowEMA int 26 Slow EMA calculation period.
InpSignalSMA int 9 Signal Line period.
InpAppliedPrice ENUM_APPLIED_PRICE PRICE_CLOSE Price type used for calculations.
InpColorMode ENUM_COLOR_MODE COLOR_BY_ZERO_LEVEL Histogram coloring methodology (see options below).
InpStrictClosed bool true Prevents repainting/flickering by referencing fully closed HTF bars.

Histogram Color Modes Explained

  1. COLOR_BY_ZERO_LEVEL (Default)

    • Blue Bar: MACD Value $\ge 0.0$ (Bullish Territory)

    • Red Bar: MACD Value $< 0.0$ (Bearish Territory)

  2. COLOR_BY_DIRECTION

    • Blue Bar: MACD Histogram is higher than the previous HTF bar (Rising Momentum).

    • Red Bar: MACD Histogram is lower than the previous HTF bar (Falling Momentum).

Installation Instructions

  1. Open MetaTrader 5.

  2. Go to File $\rightarrow$ Open Data Folder.

  3. Navigate to MQL5 $\rightarrow$ Indicators .

  4. Create or save the source code file as MACD_MTF_Custom.mq5 in this directory.

  5. Open MetaEditor (press F4 ), open MACD_MTF_Custom.mq5 , and click Compile (press F7 ).

  6. Return to MetaTrader 5, find the indicator under the Navigator window (Ctrl+N), and drag it onto your chart.


Yazarın diğer ürünleri
The MTF  MACD .mq5 indicator is a custom technical indicator designed for the MetaTrader 5 (MT5) platform . It is a Multi-Timeframe (MTF) implementation of the standard MACD (Moving Average Convergence Divergence) indicator . With the MTF capability, you can view MACD signals from a higher timeframe (e.g., H1 or D1) directly on your active chart timeframe (e.g., M5 or M15) without switching chart views . Visual Display & Features Separate Window : Displays in an indicator window below the main p
FREE
Filtrele:
Değerlendirme yok
Değerlendirmeye yanıt