Cronex DeMarker_v1

Download script
Cronex DeMarker_v1

This technical indicator is designed to help traders identify momentum and potential trend reversals by analyzing price behavior through a multi-layered mathematical approach. Instead of looking directly at raw price movements, it processes data into three distinct layers to provide a clearer picture of market sentiment.

Core Logic Overview

The tool operates by taking the standard market price and converting it into a momentum oscillator. It then applies two different types of moving averages to that oscillator to smooth out "noise" and highlight significant shifts in trend direction.

How the Data is Processed

1. The Foundation (DeMarker Oscillator) The script first calculates a "DeMarker" value based on a specific look-back period (defaulting to 25 bars). This acts as the base layer of the indicator. Its primary job is to gauge the strength of the current price movement, helping to distinguish between steady trends and erratic fluctuations.

2. The Signal Smoothing (Fast Moving Average) Rather than looking at the DeMarker value alone—which can be jumpy—the script calculates a "Fast" Moving Average based on that data. This layer acts as a responsive signal. Because it uses a shorter timeframe, it reacts more quickly to changes in momentum, helping traders spot the beginning of a shift.

3. The Trend Filter (Slow Moving Average) Finally, the script calculates a "Slow" Moving Average over a longer period. This serves as the broader trend filter. By comparing the Fast line against this Slow line, traders can better understand whether the current momentum is gaining strength or losing steam relative to the overall market direction.

How to Interpret the Results

The logic follows a "dual-line" philosophy. While the underlying DeMarker data provides the raw energy of the market, the visual focus is on the relationship between the Fast and Slow lines:

  • Momentum Shifts: When the Fast line crosses above or below the Slow line, it suggests a change in the momentum’s velocity.
  • Trend Context: By observing the distance and direction between these two lines, users can get a clearer sense of whether the market is accelerating in one direction or beginning to exhaust its current move.

By layering these three components, the tool aims to filter out minor price "hiccups" and provide a more stable visual representation of where the market's true momentum is heading.

Indicators Used
DeMarker indicatorMoving average indicator
Miscellaneous
Implements a curve of type %1
16 Views
0 Downloads
0 Favorites
Cronex DeMarker_v1
//+------------------------------------------------------------------+
//|                                              Cronex DeMarker.mq4 |
//|                                        Copyright © 2007, Cronex. |
//|                                       http://www.metaquotes.net/ |
//+------------------------------------------------------------------+
#property  copyright "Copyright © 2007, Cronex"
#property  link      "http://www.metaquotes.net/"
//---- indicator settings
#property  indicator_separate_window
#property  indicator_buffers 3
#property  indicator_color1  Silver
#property  indicator_color2  Blue
#property  indicator_color3  Red
//#property  indicator_width1  2
//---- indicator parameters
extern int DeMarker=25;
extern int FastMA=14;
extern int SlowMA=25;
//---- indicator buffers
double     DeMarkerBuffer[];
double     FastMABuffer[];
double     SlowMABuffer[];
//+------------------------------------------------------------------+
//| Custom indicator initialization function                         |
//+------------------------------------------------------------------+
int init()
  {
//---- drawing settings
   SetIndexStyle(0,DRAW_NONE);
   SetIndexStyle(1,DRAW_LINE);
   SetIndexStyle(2,DRAW_LINE);   
   SetIndexDrawBegin(1,SlowMA);
//   IndicatorDigits(Digits+1);
//---- indicator buffers mapping
   SetIndexBuffer(0,DeMarkerBuffer);
   SetIndexBuffer(1,FastMABuffer);
   SetIndexBuffer(2,SlowMABuffer);
//---- name for DataWindow and indicator subwindow label
   IndicatorShortName("Cronex DeMarker");
   SetIndexLabel(0,"DeMarker");
   SetIndexLabel(1,"Fast MA");
   SetIndexLabel(2,"Slow MA");
//---- initialization done
   return(0);
  }
//+------------------------------------------------------------------+
//| Cronex DeMarker                                                  |
//+------------------------------------------------------------------+
int start()
  {
   int limit;
   int counted_bars=IndicatorCounted();
//---- last counted bar will be recounted
   if(counted_bars>0) counted_bars--;
   limit=Bars-counted_bars;
//---- DeMarker counted in the 1-st buffer

   for(int i=0; i<limit; i++)
      DeMarkerBuffer[i]=iDeMarker(NULL,0,DeMarker,i);
//---- signal line counted in the 2-nd buffer
   for(i=0; i<limit; i++)
    {  
      FastMABuffer[i]=iMAOnArray(DeMarkerBuffer,Bars,FastMA,0,MODE_LWMA,i);
      SlowMABuffer[i]=iMAOnArray(DeMarkerBuffer,Bars,SlowMA,0,MODE_LWMA,i);
    } 
//---- done
   return(0);
  }
//+------------------------------------------------------------------+

Comments