Distance from the moving average

Custom MT4 expert advisors published here.

Moderator: admin

Distance from the moving average

Postby Alexander.Gettinger » Mon Mar 09, 2015 3:54 pm

Original LUA oscillator: viewtopic.php?f=17&t=61337.

Formulas:
Dist = Price-MA(Price) with [Length1] number of periods and [Method1] type,
Smoothed = MA(Dist) with [Length2] number of periods and [Method2] type.

Distance_From_MA_MQL.PNG


Download:
Distance_From_MA.mq4
(2.14 KiB) Downloaded 1568 times
Alexander.Gettinger
FXCodeBase: Confirmed User
 
Posts: 3785
Joined: Wed Mar 31, 2010 9:40 pm
Location: Russia, Omsk

Re: Distance from the moving average

Postby nookie » Sun May 06, 2018 4:24 am

Is it possible an Alert to be added ? and also Volume weighted MA ?

// 0 - SMA
// 1 - EMA
// 2 - SMMA
// 4 VWMA
nookie
FXCodeBase: Graduate
 
Posts: 203
Joined: Tue May 24, 2011 12:50 pm

Re: Distance from the moving average

Postby Apprentice » Mon May 07, 2018 7:30 am

Your request is added to the development list under Id Number 4135
User avatar
Apprentice
FXCodeBase: Confirmed User
 
Posts: 36341
Joined: Thu Dec 31, 2009 11:59 am
Location: Zagreb, Croatia


Re: Distance from the moving average

Postby nookie » Wed May 30, 2018 2:11 pm

Thanks, though I dont quite understand few things, like

1. what is Telegram alert?
2. what is telegram key ?

what is the alert condition that needs to be met so alert is triggered ? is it possible this to be added ?

Alert can be when there is a cross for example for both lines are >0, or both lines are < 0.

Is Volume weighted MA to be added, is it possible ?
nookie
FXCodeBase: Graduate
 
Posts: 203
Joined: Tue May 24, 2011 12:50 pm

Re: Distance from the moving average

Postby Apprentice » Thu May 31, 2018 8:55 am

Your request is added to the development list under Id Number 4114
User avatar
Apprentice
FXCodeBase: Confirmed User
 
Posts: 36341
Joined: Thu Dec 31, 2009 11:59 am
Location: Zagreb, Croatia

Re: Distance from the moving average

Postby Apprentice » Mon Jun 18, 2018 6:48 am

1. what is Telegram alert?
2. what is telegram key ?

It's a way to sent an alert to the telegram messanger.

Alert can be when there is a cross for example for both lines are >0, or both lines are < 0.

Change to this logic
Distance_From_MA.mq4
(8.54 KiB) Downloaded 855 times
User avatar
Apprentice
FXCodeBase: Confirmed User
 
Posts: 36341
Joined: Thu Dec 31, 2009 11:59 am
Location: Zagreb, Croatia

Re: Distance from the moving average

Postby nookie » Wed Jun 20, 2018 6:47 am

Thanks, few things though:

It is not refreshing, I have to go to refresh each time I would like to use it
Alerts are not showing correctly, when Line1 is >0 and Line2<0 it is showing Down alert.

Seems like also when refreshed the two lines (Line1,Line2) are not created in the same time, one is lagging over the other.

Correct would be
1. Line1>0 and Line2> 0 (or cross of Line1 and Line2 when both >0) then >UP
Last edited by nookie on Wed Jun 20, 2018 12:17 pm, edited 1 time in total.
nookie
FXCodeBase: Graduate
 
Posts: 203
Joined: Tue May 24, 2011 12:50 pm

Re: Distance from the moving average

Postby nookie » Wed Jun 20, 2018 7:05 am

Volume weighted MA added, is it possible calculation/presentation to be checked, seems not correct, I have VWMA on the chart and they seem quite different for the distance the moving average ?

If this can be fixed would be great
nookie
FXCodeBase: Graduate
 
Posts: 203
Joined: Tue May 24, 2011 12:50 pm

Re: Distance from the moving average

Postby Apprentice » Fri Jun 22, 2018 5:19 am

Can you provide your version of Volume weighted MA
User avatar
Apprentice
FXCodeBase: Confirmed User
 
Posts: 36341
Joined: Thu Dec 31, 2009 11:59 am
Location: Zagreb, Croatia


Return to MT4 Expert Advisors

Who is online

Users browsing this forum: No registered users and 14 guests

cron