Reply

EA opens order long when last now closed order was also long?

5 replies

Brett Schneideman

Subscriber, bbp_participant, community, 34 replies.

Visit profile

8 years ago #114940

Hello,

 

I want my ea to open an order in accord with my conditions and also only in the direction of the last closed order ( which may be some bars ago). Will the strategy control condition ” If  last order was long/short ” do this for me or is there another way? I generally apply my ea to three different GBP pairs on three H4 charts  at the same time (different magic numbers) so it needs to recognize the last order of the specific GBP pair on that particular chart?

 

Thanks a lot,

Brett

0

Brett Schneideman

Subscriber, bbp_participant, community, 34 replies.

Visit profile

8 years ago #136080

I should add that I realize I can probably get the result I want by simply checking only long or only short in the EA common tab but this would remove the flexibility for the EA to automatically change from taking just long positions to just short positions as trading conditions change.

0

tomas262

Administrator, sq-ultimate, 2 replies.

Visit profile

8 years ago #136102

Hello,

 

you can create a variable “last trade” and set it to +1 if you go long or -1 if you go short. Then when another signal comes along you will know what was the last trade direction. Let me know if you need an example for this.

0

Brett Schneideman

Subscriber, bbp_participant, community, 34 replies.

Visit profile

8 years ago #136107

Thanks, Tomas… yes a simple example would be helpful. Is the strategy condition  ” If last order was long ” and,  for example, rsi crossed over 50, then go long, not adequate for this?

 

Thanks, Brett

0

Brett Schneideman

Subscriber, bbp_participant, community, 34 replies.

Visit profile

8 years ago #136108

Hello, Tomas. While I have you, can you also possibly help me with another problem  that has cropped up over the last week or so and that is that my version of ea wizard is suddenly running incredibly slowly while mt4 and everything else appears to be running fine? Should I try uninstalling and reinstalling it?

0

tomas262

Administrator, sq-ultimate, 2 replies.

Visit profile

8 years ago #136142

 

I want my ea to open an order in accord with my conditions and also only in the direction of the last closed order ( which may be some bars ago)

 

So should it be “long only” or “short only” strategy? If I take trade in the same direction as previous only how do you define when to go the opposite?

0

Viewing 5 replies - 1 through 5 (of 5 total)