1) Taking multiple position but not in the same bar and 2) Trend direction

 

1 Multiple Positions

I an using the 3 ema with 0.15 deviation ( adjusted to fit as required if there are no or limited touches of the lower and upper envelopes) on th 1 hour chart with up to 10 positions. Visa Versa for Sell

I buy when the 15 ema is above the 40 ema and Bid = lower envelope with a stop of 30 pips and a target of the upper envelope

Often the target may not be reached for several bars but the Bid may hit the lower envelope a number of times on subsequent bars

How do I allow multiple positions to be taken when Bid = lower envelope but not when the Bid fluctuates above and below the lower envelope on the same bar

In summary while I want to take multiple positions on a Ccy Pair and Time chart I only want to be able to have 1 open position on a 1 hour bar

I am an Accountant using the Molanis front end to code my EA'a.

2 Trend Direction

Also is there a better way to determine the direction of Trend than the Moving Average crossovers = I am using the 15 ema and 40 ema Cross Over

I have thought of using the slope of the 5 ema - if the 5 ema (shif t2) < 5 ema (shift 1) then it is an uptrend and I only want to Buy when the Bid = lower envelope. Visa Versa for Sell.

I close whne the 5ma (shift 2) > 5 ema (shift 1)

Does anyone have other/better idea of quickly determining Trend


Thanks

 

Taking multiple position but not in the same bar. Once-Per-Bar

How do I allow multiple positions to be taken when Bid = lower envelope but not when the Bid fluctuates above and below the lower envelope on the same bar. Working-With-Doubles

I am using the Molanis front end to code. Don't use EA builders, they're very limiting + you'll have no idea how to expand or debug your codes. Use the Book.

Does anyone have a better idea of quickly determining Trend... Trend is Subjective, try using less periods for faster change (also more noise). Moderator's Trend Definition.