NexusFi: Find Your Edge


Home Menu

 





how to get data from backtest last day before ExitOnClose ?


Discussion in NinjaTrader

Updated
    1. trending_up 6,708 views
    2. thumb_up 2 thanks given
    3. group 3 followers
    1. forum 13 posts
    2. attach_file 0 attachments




 
Search this Thread
  #11 (permalink)
 choke35 
Germany
Market Wizard
 
Experience: Intermediate
Platform: Other
Trading: ES, YM, 6E
Posts: 2,622 since Feb 2013
Thanks Given: 5,101
Thanks Received: 6,558

Knowing many of the pitfalls, I for one switched to self-coded tests about 2 years ago.
Same with many of the more active traders here (some also use R, MATLAB or other additional libraries).

Just pushing my button to find out if I have the latest close in backtests (answer: yes, I do) won't help you.
Exit on close has some known issues since data sources / vendors treat settlements and last traded prices differently, which can cause misleading backtesting results.

So my advice would be: Use a regular real-time data vendor, configure correct session settings etc., then do your development and backtests.

Considering the development and backtesting methodology, I'd recommend @kevinkdog 's series of webinars. They will save you a ton of time (and/or money).

https://nexusfi.com/webinars/dec6_2012/kevin_davey_algorithmic_trading/
https://nexusfi.com/webinars/mar5_2013/developing_an_algorithmic_trading_system_kevin_davey/
https://nexusfi.com/webinars/dec4_2013/algorithmic_trading_challenge_kevin_davey/


Reply With Quote
Thanked by:

Can you help answer these questions
from other members on NexusFi?
US Treasury Weighs Direct Oil Futures Market Interventio …
Commodities
UCL Final Kicks Off at Noon ET: PSG at 56.5% as Iran May …
Prediction Markets & Event Contracts
Energy Futures Shatter All-Time Daily Volume: 8.3 Millio …
Commodities
CME Launches Bitcoin Volatility Futures June 1 -- First …
Cryptocurrency
Tradeify 3.0 Overhauls Futures Prop Firm Model -- One-Ti …
Funded Trading Evaluation Firms
 
Best Threads (Most Thanked)
in the last 7 days on NexusFi
Sober Journey With S&P
24 thanks
2026 Jlab journal
10 thanks
Lady Vols Primer: Trading Volatility Journal
8 thanks
Algo automated / semi-automated trading anyone?
6 thanks
Trying to learn Volume and price action correlation
5 thanks
  #12 (permalink)
seanMen
tel aviv
 
Posts: 7 since Aug 2015
Thanks Given: 0
Thanks Received: 1

Hi again
Thank you for your advice , i will give it a try
I manage to solve that problem by setting CalculateOnBarClose to be false.
That way i'm able to get all last backtesting day data

appreciate your help
thank you


Reply With Quote
  #13 (permalink)
 choke35 
Germany
Market Wizard
 
Experience: Intermediate
Platform: Other
Trading: ES, YM, 6E
Posts: 2,622 since Feb 2013
Thanks Given: 5,101
Thanks Received: 6,558



seanMen View Post
Hi again
Thank you for your advice , i will give it a try
I manage to solve that problem by setting CalculateOnBarClose to be false.
That way i'm able to get all last backtesting day data

appreciate your help
thank you

That error cause is nearly as basic as the session template
A caveat: Your decision comes with a price: Toggling CalculateOnBarClose to false with real-time data will result in interpreting all last prices as a "current close".
So be aware that in real trading on real-time data you will have every last tick as a (but not "the") close. Without correcting this effect with suitable time checks etc.
in your program, your testing results will not be valid for real-time use.

---

Wise decision to give methodology a try. Many beginners just get absorbed by program, backtesting, and (even more fallacious: ) optimization functions.
Then after a while they believe to have a strategy that's almost the egg of Columbus, but in fact it's only the result of overfitting past data.
Like in trading starting with methodology is important because you avoid some bad habits from the start.

Good luck!


Reply With Quote
  #14 (permalink)
 
shodson's Avatar
 shodson 
OC, California, USA
Quantoholic
 
Experience: Advanced
Platform: IB/TWS, NinjaTrader, ToS
Broker: IB, ToS, Kinetick
Trading: stocks, options, futures, VIX
Posts: 1,971 since Jun 2009
Thanks Given: 534
Thanks Received: 3,711


seanMen View Post
Im downloading free EOD data from yahoo finance via the Historical data manager

Why don't you just use the Kinetick free end-of-day feed?


Follow me on X Visit my NexusFi Trade Journal Reply With Quote




Last Updated on August 13, 2015


© 2026 NexusFi®, s.a., All Rights Reserved.
Av Ricardo J. Alfaro, Century Tower, Panama City, Panama, Ph: +507 833-9432 (Panama and Intl), +1 888-312-3001 (USA and Canada)
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.
About Us - Contact Us - Site Rules, Acceptable Use, and Terms and Conditions - Downloads - Top
no new posts