WARNING! IG Backtests are currently wrong!

Forums ProRealTime English forum ProRealTime platform support WARNING! IG Backtests are currently wrong!

Viewing 15 posts - 1 through 15 (of 19 total)
  • #21125

    Hi all!

    Please look at the attached screenshot of a 20 day simple moving average trading system.

     

    I wasted my complete sunny saturday morning trying to fix a coding error until I turned really exhausted, frustrated and angry.

    So, if you are reading this:

    Use your weekend to the fullest and don’t waste it like I did!

    Enjoy yourselves.

    #21133

    I just want to add a similar screenshot from Prorealtime. It is not happening here.

    #21137

    So this is a “long only” strategy?

    I’m currently reading the forum on my smartphone so I don’t understand clearly the screenshots you shared.

    #21138

    Yes, it is. But it is a sample strategy to explain the problem more easily.

    Guess that did not work right either…

    The screenshot shows that trades are being entered and exited without a cross in the previous period.

    #21151

    So the first screenshot is from a live account and the second one a backtest? I’m trying to understand, because I don’t notice any error in your code.

    #21156

    Hello Nicolas,

    that is what I am saying: “Backtests are currently wrong”.

    Both screenshots are from backtests. And I am also 100% sure that the code is correct. Especially since the results from the Prorealtime PRT are the way they should be.

    My partner has issued a ticket to IG and I will post the reply here.

     

    #21159

    @Nicolas: Maybe you can remove my inappropriate rant about cfd brokers from the opening post?

    #21163

    Seems like there is a problem with the “Cross over/under” function in backtest.

    After reading this post I explained a similar error here.

    Edit: Despite the rant- was it an actually explanation you were given- about the bug fix?

    Cheers Kasper

     

    #21188
    mal

    I Think it could be possible that it is right.

    At your first picture it open at 22 and close at 13, open at 19 an close at 24 …

    so this is right I think, but I didn´t understand why the system is open a position: Close = the line with green and red, Average = blue?!

    #21191
    mal

    by picture one, after the code

    #21195

    @Kasper: There is no response from IG, yet. I think I was more angry at myself then anything else. This observation does big damage to my belief that the backtested results are correct and/or the indicators are represented correct on the chart. I have noticed things like this before but always chose to go the easy way. I mean I told myseld “It’s just a temporary bug that will be fixed very soon.”.

    #21196

    @mal: I count six orders that should not have happened in the backtest. The other 3 are correct.

    #21197

    @Nicolas: Thank you. Is there an edit button and I just don’t see it?

    #21198

    @Derek, I think this is a great opportunity to address the problem, not with IG, but have it escalated to Prorealtime. You have an obvious error that is so clear and simple that it cannot be denied.

    Cheers Kasper

    #21199

    Hi,

    Maybe the problem here is different from the one I encoutered last November, but just in case it could be the same, I’ll mention it anyway:

    I also found a problem with a buy order in a backtest I did back in November and in this case I narrowed it down to a stochastic value being different from expected. Just to be 100% sure it wasn’t my code I then made a simple test “outside” of my code, looking at that stochastic value in probuilder, and running a dummy probacktest only calculating and displaying the same stochastic via Graph. I found some differences between the probuilder stochastic and the probacktest stochastic, I talked about it with Nicolas (who guessed correctly what the problem was going to be) on the PRC french forum, and also sent my tests results to PRT sincerely thinking I found a bug.

    The answer from PRT surprised me: it was because my chosen settings was “not displaying weekend data”, but the backtests are always “using weekend data” (those few ticks sunday night on CFD’s…). So on one hand I was happy to see there was neither a problem with my code nor a PRT bug creating calculations errors strictly speaking, but on the other hand, I was not so pleased to discover that if I choose not to display weekend data, that choice works only for my indicators in probuilder but it is not applied to my backtests running on PRT server side…

    This means that depending on the chosen timeframe and indicators used in my code, anything needing to look back in the past earlier than first candle monday morning, could end up with a different value than expected for things like a stochastic (in case extremes affecting it are made on a sunday). And very likely will be different for things like ema’s and macd’s that would use sunday data instead of friday’s…

    Again, I am not saying the same thing happened with your MA20 I haven’t tested it, I’m just saying what I discovered, in case the same thing applies here (which can be tested if you choose to display weekend data in the PRT timezone options)

    3 users thanked author for this post.
Viewing 15 posts - 1 through 15 (of 19 total)

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