Question on making code in ZeroCode

 

Hello all I have a question I don't understand how to do this in ZeroCode can somebody help me.....

1# I want the Parabolic Indicator to close a open trade on the last dot in the trend. I have the settings at step 0.0250 amd the max ar 0.2000

2# BUY the exchange rate when the 5 WMA crosses up past the 10 SMA

3# SELL the exchange rate when the 5 WMA crosses down past the 10 SMA

5 period WMA
10 period SMA

Thanks Much

Mike

 

Hey,

This one is easy with ZeroCode.

Firstly, setup the 3 indicators in order.

1. Parabolic SAR

2. LWMA

3. SMA

Secondly, add following logics to appropriate list:

BUY LOGICS: (Buy if WMA crosses up SMA)

AND MA (2) Previous <= MA (3) Previous

AND MA (2) Current > MA (3) Current

SELL LOGICS: (Sell if WMA crosses down SMA)

AND MA (2) Previous >= MA (3) Previous

AND MA (2) Current < MA (3) Current

CLOSE LOGICS: (Close if Par. SAR dot jumps from high to low or low to high)

AND SAR (1) Previous >= High[1]

AND SAR (1) Current <= Low[0]

OR SAR (1) Previous <= Low[1]

AND SAR (1) Current >= High[0]

Finally, fill the info and click compile. That's it! Watch the Video Walkthrough: Create a simple MACD Cross expert if you don't know how to setup indicators, add logics, or compile the mql.

 

Thanks Scorpion Yoa have an awesome system........Thanks again

Mike

 

I think I kinda understand what yousuggested did work good now if I wanted to add SAR to be part of the open where both indicators have to be inline to open......... I want to add SAR to open with LWMA and SMA on the first dot

Is this right

This one is easy with ZeroCode.

Firstly, setup the 3 indicators in order.

1. Parabolic SAR

2. LWMA

3. SMA

Secondly, add following logics to appropriate list:

BUY LOGICS: (Buy if WMA crosses up SMA)

AND MA (2) Previous <= MA (3) Previous

AND MA (2) Current > MA (3) Current

AND SAR (1) Current <= Low[0]????????is this correct

SELL LOGICS: (Sell if WMA crosses down SMA)

AND MA (2) Previous >= MA (3) Previous

AND MA (2) Current < MA (3) Current

AND SAR (1) Current <= Low[0] ????????is this correct

CLOSE LOGICS: (Close if Par. SAR dot jumps from high to low or low to high)

AND SAR (1) Previous >= High[1]

AND SAR (1) Current <= Low[0]

OR SAR (1) Previous <= Low[1]

AND SAR (1) Current >= High[0]

Thanks Again

 

TT, could you explain a bit more? I can't understand what u're saying.

 

Sorry Scorpion, what I meat was

2# BUY the exchange rate when the 5 WMA crosses up past the 10 SMA and past the first dot on the Parabolic is on open trade

3# SELL the exchange rate when the 5 WMA crosses down past the 10 SMA and past the first dot on the Parabolic is on open trade

Thanks Much

Mike

 

Hey, it should be something like this:

BUY LOGICS: (Buy if WMA crosses up SMA and passes Sar)

AND MA (2) Previous <= MA (3) Previous

AND MA (2) Current > MA (3) Current

AND MA (2) Current > SAR (1) Current

SELL LOGICS: (Sell if WMA crosses down SMA and passes Sar)

AND MA (2) Previous >= MA (3) Previous

AND MA (2) Current < MA (3) Current

AND MA (2) Current < SAR (1) Current

Hope I understand your statement well.

Reason: