Tick generation - Open bar only - page 2

 
Plymo:


That said, not all is lost yet.

 

Still I'm very much open to smart suggestions from other developers or MetaQuotes.

 

I still want MQL5 but do finish it faster and with no bug/problems. ATC2010 stays to come in ...

 

My multicurrency strategy concept is like this example/proof of concept which needs pairs synchronization.

At bar time T or shift 1 on EURUSD M15 we check stochastic also at bar time T/shift 1 for EUR vs All currencies: eg: get stochastic or EURAUD,EURCAD,EURJPY,EURGBP,EURCHF at shift 1 and make an average A1

we also check the same for quote USD vs All: eg. get stochastic AUDUSD(inverted),USDCAD,USDJPY,GBPUSD(inverted),USDCHF at shift 1 and make an average A2

Now, if A1 < 20 (oversold) this indicates EUR power (as principle) vs All might rise; idem if A2 > 80 (overbought) this indicate USD vs All might go down,

so, if EUR goes up and USD goes down vs All pairs, what is expected EURUSD to do ?  I think it will go up, so Buy EURUSD, especially if stochastic EURUSD < 20 ? no ?

So, we practically trade only EURUSD but we take care of the whole market. It appears to be a single currency strategy, but it isnt; it is a multicurrency strategy.

The problem is that at bar time X, or shift 1 all pairs mut have correct values and be synchronized in time; for current build it appears they are not.

I was not able to get them working. It appears I should get/copy a bunch of arrays on each pair and look for the bar time required instead using simple shift 1 as in MT4 or JForex.

 Regards,

 

Yes, I've been busying myself with other functionality of my EA lately, but it seems you have pounded down the right approach.

If your bar is returned wrong for the foreign chart's time, "manually" shift time and do your calculations. You can still consider this pair's 0 bar as "closed". I never learned MT4 so this solution has been easy for me to accommodate  in my plan -- but not into code. :) We'll see, and if at all possible we should share some info here once somebody has the functionality working.

I am certainly looking forward to competing -- if I can make it in time!