PDA

View Full Version : Long Bar Shadow during Backtesting.


tjendra
03-24-2009, 03:20 AM
When I do a visual inspection of the strategy in the Chart Tab, I notice for SPY Bar Charts, there are alot of very long shadow lines. When this line hit my stop loss, the stop loss gets executed. But the point is, the long shadows are obviously incorrect. During live trade, will I get stopped out if such incorrect bars appear? Is there any way to prevent such incorrect bars during backtesting?

NinjaTrader_Bertrand
03-24-2009, 03:34 AM
Which datafeed are you using?

Yes, if you get a so called 'bad tick' in realtime it can trigger your stops.

For this you could use our realtime tick filter - http://www.ninjatrader-support.com/HelpGuideV6/Real-timeTickFiltering.html

tjendra
03-24-2009, 05:16 AM
Which datafeed are you using?

Yes, if you get a so called 'bad tick' in realtime it can trigger your stops.

For this you could use our realtime tick filter - http://www.ninjatrader-support.com/HelpGuideV6/Real-timeTickFiltering.html

I am using IB feed. What would be a typical value for "Bad tick offset as %" value? Attach a pic of the long shadow I am talking about.

NinjaTrader_Bertrand
03-24-2009, 05:23 AM
There is unfortunately no real 'typical' value, you will have to test this for the instruments you use, however you can start with the 0.1 % per default for testing. Have you tried to reload your historical data (right click on the chart > Reload Historical Data)?

tjendra
03-24-2009, 05:30 AM
On the Strategy Analyser chart, there is no option to reload historical data on the right click? I also notice the Chart in the Strategy Analyser has more long shadows than normal charts I am using for the same ticker. Why is that so?

Does adding the tick filter remove the long shadow? Or it just mean the indicators or strategies won't act on it?

NinjaTrader_Bertrand
03-24-2009, 06:21 AM
Enabling it will filter out the ticks that fall in the specified range from the real time data stream you receive, so the strategies receiving won't react when those come in. It will not work on your historically downloaded data.

To reload your data from IB, you can also use the option in the Control Center (Tools > Historical Data > Reload).

Are you using the same charting interval in both your charts and the Strategy Analyzer?

tjendra
03-24-2009, 06:35 AM
Yes I am using the same interval, that's why I was quite surprised one came without the shadows and one with them even thought they are from the same feed.

If I reload the historical data from IB with the tick filter enabled. Does it get rid of the long shadows in the chart during backtesting?

NinjaTrader_Bertrand
03-24-2009, 07:26 AM
It could also be visual due to another scaling being used for the normally smaller Strategy Analyzer chart...the reload can fix those bad ticks if the data has been fixed on the server side from which you reload your data. The filter will not have any effect on the historical data, it will only work on realtime incoming data.

Serninja
02-01-2011, 10:50 AM
Hello Bertrand,

I've the same issue but on all bars. This is the first time I have this issue, after I imported a new instrument from the instrument list yesterday. Seemingly the current bars are printing correctly now. I've reset the database with no success. I don't have any errors in my log file regarding this and the instrument works fine on my brokerage charting platform.

Thank you in advance.

Kind regards,

NinjaTrader_Bertrand
02-01-2011, 11:20 AM
Serninja, on which NT version (Help > About) and brokerage technology are you working here? If you reset instruments, restart NT and then force a reload of historical data with a right click on the chart - would you still see the same issue?

Serninja
02-01-2011, 11:45 AM
Hello Betrand,

thanks for your reply. NT 7.0.1000.1. Unfortunately this doesn't solved the issue. And now the latest bars which have been plotting correctly are again with shadows.

Regards,

NinjaTrader_Bertrand
02-01-2011, 12:41 PM
Can you please upgrade to latest NT7 R2 via Help > Download Site and then recheck? Also: which datafeed or broker are you using in this scenario?

Thanks,

Serninja
02-02-2011, 06:49 AM
Hello Bertrand,

thanks for your reply.

I've just updated NT7 and the PFGBest API. Then reinstalled NT7 due to API issues, which occur every time. After a time consuming procedure and NT7 takes pity with me and accepts the new API, I thought it would work now. But, NO.

This neither works on my desktop PC nor on my notebook. Like I said before, I've checked all the instruments with my brokerage charting platform and they work fine there. I also contacted PFG, and they said everything is OK. Please could you check the instrument database on your side, notably the interest rate futures.

Regards,

NinjaTrader_Bertrand
02-02-2011, 08:06 AM
Serninja, please post a screenshot of your ZB master instrument settings for example - I just checked here on NT7 and a PFG live account and the data I see looks correct.

Serninja
02-02-2011, 08:33 AM
Hello Bertrand,

here are two screenshots from the Instrument Editor of ZB and ZF whereby ZF is not working properly. ZT is also not working but ZN is working. I've also reloaded data via Historical Data Manger without success. You can take a look at the chart screenshot for a better view.

Regards,

NinjaTrader_Bertrand
02-02-2011, 08:41 AM
Thanks, I'm seeing the same here for minute based data for ZF and ZT - tick based data seems to be ok, can you confirm this, too?

Thanks,

Serninja
02-02-2011, 09:51 AM
Hello Bertrand,

thank you too for your kind and quick support.

Yes, seemingly only minute data is somehow corrupted but I can't trust any "graphic rendition" if I see obviously flawy charts like this. Should I compare tick based charts with my brokerage platform by taking some screenshots or do you have enough information to solve the issue? And by the way the bars are printing correct since the last database reset, but if i reset the database again then the bars are plotting again completely incorrect.

Thanks again for your great support!

Kind regards,

NinjaTrader_Bertrand
02-02-2011, 09:56 AM
Serninja, we're looking into matters right now and will contact PFG, too - if you could it would be great to hear if tick charts compare well for you.

Serninja
02-02-2011, 10:18 AM
Hello Bertrand,

sorry for being hasty but I just realized, no tick based charting platform.

Regards,

NinjaTrader_Bertrand
02-02-2011, 10:29 AM
No worries - we're looking into the min data issue.

Serninja
02-08-2011, 07:52 AM
Hello Bertrand,

have you been able to fix the min data issue on the interest rate instruments with PFG?

Unfortunately I can't see any improvement on my charts...

Kind regards,

NinjaTrader_Bertrand
02-08-2011, 09:22 AM
Serninja, from our testing here the issue lies in the data that being send out by the PFG servers - it would be best if you contacted PFG directly on the data.