Strategy doesnt open position live but does so in backtest

Forums ProRealTime English forum ProOrder support Strategy doesnt open position live but does so in backtest

Viewing 14 posts - 1 through 14 (of 14 total)
  • #37289

    I just experienced something i don’t understand.

    I have a strategy running live and it should have opened a position a few candles ago because all conditions were met (i double checked this with graph). In backtest the strategy opens a position like it should but on my live-account didn’t happen anything.

    Any ideas what could be the problem?

    #37302

    I had a situation a couple of months ago where I put a new version of a system live and it appeared to be running but after 2 days I realised it had not taken 3 positions that it should have done as indicated by the backtest.  When I checked it was an issue with an insufficient number of bars being pre-loaded i.e. via DEFPARAM PRELOADBARS.  Normally when this happens and it has happened to me a few times the system will stop almost immediately and appear in the not running section with a yellow warning triangle but in this case it appeared to be still running but was doing nothing.  So worth checking that out.

    1 user thanked author for this post.
    #37316

    Check the orders lists (CTRL+O), your orders may have been refused by the server because of too tight stop, wrong prices, etc..

    #37339

    I think AutoStrategist nailed it. I forgot to preload any bars. That might cause problems loading one indicator. I will try that. Thanks!

    #37343

    Default Preload Bars are 200 and usually a Bot is stopped (as AS said  … appear in the not running section with a yellow warning triangle).

    As Nicolas says … check the orders lists (CTRL+O) under Cancelled / Rejected Tab … I’ve had this happen loads of times (but the Bot doesn’t appear in not running section until after maybe 12 + Rejections?).

    GraHal

    #37359

    I had this before with the yellow warning sign but this time was different. The strategy was running but generated no orders at all. Also none that was canceled or rejected.

    I now added defparam preloadbars=500 and will see next week if the bot is taking a trade.

    1 user thanked author for this post.
    #37758

    I have now another strategy running that does the same – that means that doesnt open a position on my live-account but does so when backtesting. I have added preloadbars=500 to this one (which should be plenty) but anyway.

    There are no rejected orders or anything similar. The strategy simply doesnt open a position live although all conditions are met.

    Any ideas anyone?

    #37765

    I guess you don’t want to add the code on here as this is the easiest to make a diagnosis?

    What market is it and what spread have you got in your backtest engine?

    Try preload bars 2000, maybe seems no logic in it, but you need to make a change today else tomorrow will be the same as yesterday! 🙂

    #37766

    Unless you share the code, it will be difficult to know what may cause the problem. Are the codes version the same between the backtest and the previous code sent to ProOrder?

    #37778

    The strange thing is that I run this strategy on other securities and it works fine (little bit different variables though) with all other currency pairs. Just GBP/USD is behaving weird.

    I even ran it on my demo account and also there it opens trades but on my live-account it just sits there and does nothing. 🙂

    I will figure out what caused this and share it with you all. Sometimes this bugs are really funny.

    I also understand that if i don’t share my code it is hard to help. Anyway i don’t want to share strategies i run live and put many hours work into. Sharing a strategy that is still in development stage is something different. But this strategy is already making good profits on 6 other securities, just GBP/USD doesn’t work. Worst case i won’t run it on GBP/USD and i can live with that but i have a hard time to accept that it is not working and i don’t know why. 🙂

    #37825

    Sharing a profit making strategy won’t reduce profit / turn it into a loss making strategy.

    Share on here and your Strategy may end up even more profitable for you as there are some very clever / innovative coders on here who also know more about Trading than you or I will ever know? 🙂

    Just a few Thoughts
    GraHal

    #37845

    I will think about it. 🙂 First I’ll try your idea and set preloadbars=2000. This worked once before when a strategy of mine produced this yellow triangle. Also when this helped I used no indicator that would require so many bars. Sometimes PRT really is little funny…

    #37855

    @Despair, can be easy to miss, for example using Dclose(5) in a 5M chart requires 5 x 24 x 12 bars to be pre-loaded

    2 users thanked author for this post.
    #38150

    Preloadbars=1000 solved the problem. Now the strategy opens trades like it is suppossed to.

    1 user thanked author for this post.
Viewing 14 posts - 1 through 14 (of 14 total)

Create your free account now and post your request to benefit from the help of the community
Register or Login