Help Needed formula For Price Crossover Moving Average

V.V.

Active Member
#1
Dear Jenious,
I am new to Metastock. I like to get Formula for Below Condition. Please Help Me.

Condition :
Buy Signal:-
i) I want create Buy Signal "When Moving average 50 Crossover the price & After the Price go above ten points"

[ Please Assume If Nifty Price is 3600. Movingaverage 50 is now crossover the price=3600, after then Nifty go up to 3610 now I want show Buy Signal in 3610. ]

I USE HERE ONLY ONE MOVING AVERAGE.

ii) I want create Sell Signal "When Moving average 50 Crossover the price & After the Price go Below ten points"

[ Please Assume If Nifty Price is 3600. Movingaverage 50 is now crossover the price=3600, after then Nifty go Down to 3590 now I want show Sell Signal in 3590. ]


I am waiting for yours reply.

Regards
V.V.
 

AW10

Well-Known Member
#2
VV,

I believe in "Teach a man fishing .." so giving you some pointers here.
Goto Metastock "Enhanced System Tester" ($ icon on panel). There is a sytem "Equis - Moving Average Crossovers" already provided for Metastock.
This generates buy sell signal, based on crossover of 2 moving averages.
Please play around with this. Add addition condition to see that closing price is > 10 from moving average value etc..
and you will have the new system with you..

Happy Trading.
 

V.V.

Active Member
#3
Dear Sir,
Thanks For Your Great Reply. I viewed "Enhanced System Tester" in metastock, after your command. But I couldn't Understand, B'cause I am new to this. Here I want Buy & Sell Signal Crossover only 1 Moving Average (Ma,50, S) . So can you help to give a formula for this condition? .

Thanks & regards
V.V.


VV,

I believe in "Teach a man fishing .." so giving you some pointers here.
Goto Metastock "Enhanced System Tester" ($ icon on panel). There is a sytem "Equis - Moving Average Crossovers" already provided for Metastock.
This generates buy sell signal, based on crossover of 2 moving averages.
Please play around with this. Add addition condition to see that closing price is > 10 from moving average value etc..
and you will have the new system with you..

Happy Trading.
 

rkkarnani

Well-Known Member
#5
Am no expert in coding, but this may help you :

Open Meta stock
Click on Expert Advisor
Click New
Type Name :50SMAcrossover or whatever
Click on Highlight Tab
Click New
Name it : Buy
Type in Condition Window :
a:=Mov(C,50,S);
H >= a+10

Choose colour Blue or green whatever
Click : OK

Again click New
Name it Sell
Type in condition window :
a:=Mov(C,50,S);
L <= a-10

Choose colour : Red
Click : OK

Click OK again of the Main Window of the Expert Advisor

Now when you apply this Advisor on Nifty, the bars shall Turn Blue as and when the High of a Bar is 10 points above the 50 Period Simple moving average!!! And the bars shall be red when the Low is 10 points lower than 50 period SMA!!!
You may add Symbols etc in Symbol Tab under Main expert advisor window!!

Praying that it works!!! I tried it and to me it seems to be working alright!!! Give it a try!!! You can always delete it if it doesnt work!!!! :D
 

V.V.

Active Member
#6
Dear rkkarnani sir,

Thanks Thanks Thanks a Lot. I Tried Your Method.Please Find the Attachment File. I was Expecting for this . Its Good. But I like to Get Buy, Sell & Cover Signal for this below condition.

==========================================================
Long :-
======
1) MA Crossover Above the Price (AND) After Price goto + 10 Points ===> Buy Signal
2) After I got Buy signal Price + 20 Points (Profit Booking) ===> cover Signal

Stoploss (Exit Long) :-
=================
1st condition true but second condition false then I should show Long Cover (Stoploss) Signal.
Condition : MA Crossover Below the Price -10 Points === Exit Long Signal

Short :-
======
1) MA Crossover Below the Price (AND) Price goto -10 Points ===> Sell Signal
2) After I got sell signal Price + 20 Points (profit Booking) ===> cover Signal

Stoploss (Exit Short) :-
=================
1st condition true but second condition false then I should show Short Cover (Stoploss) Signal.
Condition : MA Crossover Above the Price (AND) Price goto + 10 Points ===> Exit Short Signal
==========================================================



Can you help to Create Expert fot this Condition ? Once again Thanks for your Valuble Information .


Regards,
V.V.
 
Last edited:

V.V.

Active Member
#7
Am no expert in coding, but this may help you :

Open Meta stock
Click on Expert Advisor
Click New
Type Name :50SMAcrossover or whatever
Click on Highlight Tab
Click New
Name it : Buy
Type in Condition Window :
a:=Mov(C,50,S);
H >= a+10

Choose colour Blue or green whatever
Click : OK

Again click New
Name it Sell
Type in condition window :
a:=Mov(C,50,S);
L <= a-10

Choose colour : Red
Click : OK

Click OK again of the Main Window of the Expert Advisor

Now when you apply this Advisor on Nifty, the bars shall Turn Blue as and when the High of a Bar is 10 points above the 50 Period Simple moving average!!! And the bars shall be red when the Low is 10 points lower than 50 period SMA!!!
You may add Symbols etc in Symbol Tab under Main expert advisor window!!

Praying that it works!!! I tried it and to me it seems to be working alright!!! Give it a try!!! You can always delete it if it doesnt work!!!! :D

Dear rkkarnani Sir,


Can you give Amibroker AFL using with Above your formula ?


Regards,
V.V.
 

Similar threads