Open order on last tick/end of bar?

Back to topics list To post a new topic, please log in or register
avatar
15
codeMolecules 2015.03.23 00:19
 

Hello forum, good day.

Is it possible to know when the bar ends and place an order right at the last tick? I know that the easy way would be to wait until new bar event and do it on first tick, but I need to place the order right at the last tick/end of a bar. Could this be done?

Best regards and thank you,

codeMolecules 

avatar
Moderator
3404
GumRai 2015.03.23 00:47 #
 
There is no way of knowing whether a tick will be the last tick of the bar
avatar
1211
deysmacro 2015.03.23 01:02 #
 
GumRai:
There is no way of knowing whether a tick will be the last tick of the bar
But you would know when the current bar will reach its time before new bar developed.
avatar
15
codeMolecules 2015.03.23 01:32 #
 
deysmacro:
But you would know when the current bar will reach its time before new bar developed.

Hello deysmacro, thanks for your response. 

So this could be almost the same as knowing when the last tick of a bar is and then place an order just before new bar, correct? How could this be done?

Your help will be much appreciated. 


Best regards and thank you,

codeMolecules 

avatar
1211
deysmacro 2015.03.23 01:37 #
 
codeMolecules:

So this could be almost the same as knowing when the last tick of a bar is and then place an order just before new bar, correct?

Sorry. Not the same. Every bar developed in a preset timing. So, get the timing and open new order in the last few seconds of the current bar.
avatar
12983
WHRoeder 2015.03.23 13:27 #
 
deysmacro: . So, get the timing and open new order in the last few seconds of the current bar.
And what if there is no tick in the last few seconds of the bar. During Asian session there can be many minutes between ticks

avatar
16
xiruko 2015.03.23 13:49 #
 

It is not possible to check whether a tick is the last in a bar or not, but if you are using long timeframes like H1 or more, you could check for the last M1 bar for each H1 bar. I know this is not the last tick, but could be a workaround.

 

avatar
1211
deysmacro 2015.03.23 14:20 #
 
WHRoeder:
deysmacro: . So, get the timing and open new order in the last few seconds of the current bar.
And what if there is no tick in the last few seconds of the bar. During Asian session there can be many minutes between ticks

I know the workaround. No need to depend on ticks.
Back to topics list  

To add comments, please log in or register