Problem with stategy

Section for discussions related to indicators, use of indicators, and building of trading stategies using indicators.

Moderator: admin

Problem with stategy

Postby Scrat_Power » Wed Aug 21, 2013 6:10 am

Hi all,

Here my problem using strategy.
I post here because i tried to find a solution but i am at the end of road.

I developped an indicator that give me signals when i need to buy or sell.
I developped a strategy that use these signals to take orders and do some kind of money management (running on closing bar, not at tick).

When i backtest all of this, all is nice and kind.
But when i play in real (either on demo or real account), i miss some orders.
The indicator that is playing on the interface give me the information, but not the strategy that is using the same indicator.

I have read that the Trading Station is asynchronous and it can happen that some ticks are missed.
As the "new bar" event is activated with the new 1st tick of the new beginning bar, is it possible that the "new bar" event was missed ?

If you have some answer or solution, i will be please to take it.

Wtih regards,
Scrat.

PS : Sorry if i make some english mistakes but it is not my born language.
User avatar
Scrat_Power
 
Posts: 26
Joined: Tue Aug 21, 2012 2:56 pm

Re: Problem with stategy

Postby Valeria » Thu Aug 22, 2013 12:58 am

Hi Scrat,

The "new bar" event can't be missed.
It would be great if you sent me the code of the strategy and the indicator here or via private message, because it is hard to understand the issue and give you advice without the code.
Valeria
 

Re: Problem with stategy

Postby Scrat_Power » Thu Aug 22, 2013 6:04 am

Hi,

Thanks for the answer.
I have made several more tests and log a lot of parameters in the strategy.

I found where is the bug but i haven't any solution to resolve it.

In the strategy, i am using the Indicator:update(core.UpdateLast) command to update my indicator with lastest bar received.

core.UpdateLast : the strategy miss some signals from the indicator as the lastest bar was not here
core.UpdateAll : all is ok and all signals are received

So, i don't understand why the UpdateLast is not properly functional.
I can't use the UpdateAll as it's very CPU consuming to recalculate all the indicator stream at each new bar.

Do you know this issue ?

Regards,
Scrat.
User avatar
Scrat_Power
 
Posts: 26
Joined: Tue Aug 21, 2012 2:56 pm

Re: Problem with stategy

Postby Valeria » Thu Aug 22, 2013 10:38 pm

Hi Scrat,

Unfortunately, your answer does not clear up the situation. Could you please send me your strategy, because most likely the bug is in the code.
Valeria
 


Return to Discussions

Who is online

Users browsing this forum: No registered users and 22 guests