Ninjatrader and backtesting - NinjaTrader Programming | futures io social day trading
futures io futures trading

Ninjatrader and backtesting
Updated: Views / Replies:1,964 / 3
Created: by ehlaban Attachments:0

Welcome to futures io.

(If you already have an account, login at the top of the page)

futures io is the largest futures trading community on the planet, with over 100,000 members. At futures io, our goal has always been and always will be to create a friendly, positive, forward-thinking community where members can openly share and discuss everything the world of trading has to offer. The community is one of the friendliest you will find on any subject, with members going out of their way to help others. Some of the primary differences between futures io and other trading sites revolve around the standards of our community. Those standards include a code of conduct for our members, as well as extremely high standards that govern which partners we do business with, and which products or services we recommend to our members.

At futures io, our focus is on quality education. No hype, gimmicks, or secret sauce. The truth is: trading is hard. To succeed, you need to surround yourself with the right support system, educational content, and trading mentors Ė all of which you can find on futures io, utilizing our social trading environment.

With futures io, you can find honest trading reviews on brokers, trading rooms, indicator packages, trading strategies, and much more. Our trading review process is highly moderated to ensure that only genuine users are allowed, so you donít need to worry about fake reviews.

We are fundamentally different than most other trading sites:
  • We are here to help. Just let us know what you need.
  • We work extremely hard to keep things positive in our community.
  • We do not tolerate rude behavior, trolling, or vendors advertising in posts.
  • We firmly believe in and encourage sharing. The holy grail is within you, we can help you find it.
  • We expect our members to participate and become a part of the community. Help yourself by helping others.

You'll need to register in order to view the content of the threads and start contributing to our community.  It's free and simple.

-- Big Mike, Site Administrator

Thread Tools

Ninjatrader and backtesting

Elite Member
Futures Experience: Advanced
Platform: Ensign, Multicharts
Favorite Futures: SP500
Posts: 95 since Nov 2009
Thanks: 66 given, 56 received

Ninjatrader and backtesting

I'm in the process of starting with backtesting some ideas. As i'm evaluating
some programs for simple backtesting i now want to start with Ninjatrader.

I can remember by reading this forum that there are some issues with Ninja 7
with backtesting. I've read that results change and/or results are not always dependable.

Can somebody knowledgeble about Ninja say something if these issues are genuine
and do exist as perhaps i'm mistaken.

Now this is a honest question and i do not want to bash Ninja so if we can just discuss
if there are some things to watch out for or to handle in a special way.

Quick Summary
Quick Summary Post

Quick Summary is created and edited by users like you... Add FAQ's, Links and other Relevant Information by clicking the edit button in the lower right hand corner of this message.

Elite Member
Futures Experience: None
Platform: None Yet
Favorite Futures: Guitar
MrYou's Avatar
Posts: 403 since Jun 2011
Thanks: 618 given, 194 received

Someone correct me if I'm wrong, but the gist of it is...

The issue has to do with "intra-bar granularity". You can see the effect when your strategy only operates on the primary time period/frame (BarsInProgress = 0), but when you simply add a new time period your results change even though your strategy does not interact with this additional time period.

The workaround suggested by NinjaTrader is to make your entries on a higher time period such as a tick or minute chart. For example: EnterLongLimit(1, Close[0]); Which enters on the secondary time period within the strategy.

So what I do is compare the backtesting results of one day to the Market Replay results of the same day. If I get somewhat closer results then I'm a little more confident in the backtesting results as a whole. Next I will sim/paper trade the strategy with live data, which is where I am with my trading journey.

Here are some NinjaTrader Support provided links:

NinjaTrader Version 7
Strategy: Backtesting NinjaScript Strategies with an intrabar granularity - NinjaTrader Support Forum

I'm hopeful this will be fixed in the "next-gen" version of NinjaTrader.

The following 2 users say Thank You to MrYou for this post:
Elite Member
London, UK
Futures Experience: Beginner
Platform: NinjaTrader, home-grown Java
Broker/Data: IB/IQFeed
Favorite Futures: EUR/USD
Adamus's Avatar
Posts: 1,085 since Dec 2010
Thanks: 471 given, 778 received

IMHO I find most people expect more than is reasonable from backtesting software. As in most things, it pays to keep things simple. I always make sure that I have very very few trades where the entry and the exit are on the same bar in the backtest results. If your software - NT7, TS, whatever - is hitting exits on the same bar as entries, I think you are asking too much of the software to cope with the situation in a way that reflects real life.

Personally I would programme my own backtesting software to be pessimistic and that if the bar hits both the target and the stop on the same bar, then it chooses the stop.

You can discover what your enemy fears most by observing the means he uses to frighten you.
The following user says Thank You to Adamus for this post:


futures io > > > > > Ninjatrader and backtesting
Thread Tools

Upcoming Webinars and Events (4:30PM ET unless noted)

July Journal Challenge - $500 in Amazon Gift Cards!


AXESS Trader: Powerful Cloud Based Trading Platform w/GFF Brokers

Jul 17

TBA: FuturesTrader71 w/Morad Askar

Elite only

Similar Threads
Thread Thread Starter Forum Replies Last Post
VIDEO: MultiCharts vs. NinjaTrader strategy backtesting and optimization Big Mike MultiCharts 53 June 12th, 2016 01:34 PM
Ninjatrader vs. Metatrader for Backtesting and Realtime Analysis FX janson Platforms and Indicators 4 January 31st, 2012 11:32 AM
Backtesting Big Mike Terms (Glossary) 0 June 27th, 2010 05:42 AM
Help with backtesting nqemini Traders Hideout 5 January 16th, 2010 11:00 AM
Can NinjaTrader data be stored other than \My Documents\NinjaTrader 6.5 tc12357 NinjaTrader 4 December 15th, 2009 01:55 PM

All times are GMT -4. The time now is 08:19 AM. (this page content is cached, log in for real-time version)

Copyright © 2018 by futures io, s.a., Av Ricardo J. Alfaro, Century Tower, Panama, +507 833-9432,
All information is for educational use only and is not investment advice.
There is a substantial risk of loss in trading commodity futures, stocks, options and foreign exchange products. Past performance is not indicative of future results.
no new posts
Page generated 2018-07-16 in 0.09 seconds with 14 queries on phoenix