Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

How not to cheat in backtest?

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

    How not to cheat in backtest?

    I used the wizard to create a simple %K crossover strategy with a 10 tick target and 1 tick trailing stop in the YM contract on a 15 minute timeframe.

    In real live trading this would almost always get stopped out at a loss, but the Strategy Analyzer thinks it's a fantastic idea. Giving the backtest a virtual straight line up profit curve.

    It's set to calculate on close. What other settings or precautions are needed to ensure no peeking into future data on indicator calculations and the limit and stop orders are executed in the order that they would have occurred?

    #2
    Backtests in NinjaTrader do not peek into the future. The problem is the granularity of your stop and targets. I suspect a lot of your entries and exits are on the same bar? If yes, this is the problem and you will be hard pressed to get a better back test result. The reason is, in a 15 min bar that is 30 ticks high to low, you will not know if the stop or target is hit first. Thus we can't tell which order the orders would have really been filled.
    RayNinjaTrader Customer Service

    Comment

    Latest Posts

    Collapse

    Topics Statistics Last Post
    Started by AaronKoRn, Yesterday, 09:49 PM
    0 responses
    11 views
    0 likes
    Last Post AaronKoRn  
    Started by carnitron, Yesterday, 08:42 PM
    0 responses
    10 views
    0 likes
    Last Post carnitron  
    Started by strategist007, Yesterday, 07:51 PM
    0 responses
    12 views
    0 likes
    Last Post strategist007  
    Started by StockTrader88, 03-06-2021, 08:58 AM
    44 responses
    3,982 views
    3 likes
    Last Post jhudas88  
    Started by rbeckmann05, Yesterday, 06:48 PM
    0 responses
    10 views
    0 likes
    Last Post rbeckmann05  
    Working...
    X