Moving Average - page 53

Eddy Taylor
75
Eddy Taylor  

What is the coding for a 12 day EMA?

I am so new to proraming and keep getting it wrong .

!

I'm wondering if anyone would be kind enough to give me the MQL4 coding for a 12 day EMA. If you give me the syntax for these calculations in MQL4, it would help as well;

1. 12 day EMA - 26 EMA

2. William's %R 14 day Simple MA

Also, I want to view my 12 day EMA - 26 EMA as a line and a histogram. What should I do to convert it from one form to the other?

Thank you ever so much.

andre
5
andre  

histo

Eddy-2d:
I am so new to proraming and keep getting it wrong .

!

I'm wondering if anyone would be kind enough to give me the MQL4 coding for a 12 day EMA. If you give me the syntax for these calculations in MQL4, it would help as well;

1. 12 day EMA - 26 EMA

2. William's %R 14 day Simple MA

Also, I want to view my 12 day EMA - 26 EMA as a line and a histogram. What should I do to convert it from one form to the other?

Thank you ever so much.

don't understand what you say ? 1. 12 day EMA - 26 EMA ?

do you need a difference ? if so (MACD 12,26,x) will do

for your first question =

change the Buffer

SetIndexStyle(0,DRAW_LINE);

into

SetIndexStyle(0,DRAW_HISTOGRAM);

kino

fxbs
3203
fxbs  

Ind-GG01 mod, GGekko

description: GG01 and GG01-101 indicator - MQL4 Code Base

Files:
MindyR
5
MindyR  

Looking for a percentile based Moving Average Channel

Does anyone know of, or have the ability to code, an MT4 indicator to create a moving average channel like that described by Gerald Appel (yes, the originator of MACD) - here's an article about how he uses it:

Current Issue

All the channels I've been able to find are based on using one MA for the top channel and another for the bottom channel (such as on the high and the low, or different lengths for the MA).

His system is based on having the MA as the center line of the channel, and the upper and lower bounds are a percentage greater and lower than that, like 8% more and less for instance. This results in a channel of steady width that moves with price. He sets that percentage to encompass about 95% of price action (a visual and subjective setting).

As with other channels, signals are then generated by how price interacts with the upper and lower bounds - but it tells you more than just buy and sell - it also tells you when a trend is losing steam and getting ready to reverse.

If anyone could help me by creating this, I'd be very appreciative! Thanks in advance!

Linuxser
5921
Linuxser  
MindyR:
Does anyone know of, or have the ability to code, an MT4 indicator to create a moving average channel like that described by Gerald Appel (yes, the originator of MACD) - here's an article about how he uses it:

Current Issue

All the channels I've been able to find are based on using one MA for the top channel and another for the bottom channel (such as on the high and the low, or different lengths for the MA).

His system is based on having the MA as the center line of the channel, and the upper and lower bounds are a percentage greater and lower than that, like 8% more and less for instance. This results in a channel of steady width that moves with price. He sets that percentage to encompass about 95% of price action (a visual and subjective setting).

As with other channels, signals are then generated by how price interacts with the upper and lower bounds - but it tells you more than just buy and sell - it also tells you when a trend is losing steam and getting ready to reverse.

If anyone could help me by creating this, I'd be very appreciative! Thanks in advance!

I've read Appel's book several times.

Just drop indicator envelopes that comes by default with MT4

ecuaforex
24
ecuaforex  

Hola, MindyR

Files:
ma_kanal.tpl 5 kb
ma_kanal.mq4 13 kb
MindyR
5
MindyR  

thanks for the kanal

Thank you for this great indicator! and the template too. It's beautiful!!!

A question.... why did you pick 55 as the base moving average for your template?

Just curious...

Thanks again!

Mindy

ecuaforex
24
ecuaforex  
Sonn
3
Sonn  

Price distance from MA

Dear friends,

I'm new to Metatrader and I find this thread very helpful. I am looking for a indicator that measures the distance (pips or %) between the current price and a MA.

Hiachiever's code is near from that but it's not really an indicator.

Thanks a lot.

mmil
3
mmil  

I ask your help to code a simple indicator...

Hi guys I am sorry but I need your help to code this simple indicator:

I am talking about an indicator based on the difference between two CMA (Centered Movig Average) more precisely the difference between a Fast CMA less a Slow CMA (obviously with the possibility to set MA periods), shown in a separate window as an oscillator_

this is the first indicator we call CTLM...

The second indicator, which derives directly from the first indicator, with the following characteristics:

CTLM-(CTLM -1) the difference between the value of CTLM less the value of CTLM's previous bar... Clearly on separate window as an oscillator and we call this second indicator CTLMSpeedOscillator_

Now it must be said that this type of MA (centered MA) is rarely used because it has a structural defect, probably few traders know and use this type MA, then I attack this indicator by which we can start to develop CTLM and CTLMSpeedOscillator oscillators_

The following indicator should be a good formula to start, of course if someone knows a better formula of CMA this would be much appreciated!

Thanks in advance for your willingness, my best regards.