NinjaTrader Support Forum  
X

Attention!

This website will be down for maintenance from Friday May 24th at 6PM MDT until Saturday May 25th at 11AM MDT. We apologize for the inconvenience. If you need assistance during this time, please email sales@ninjatrader.com


Go Back   NinjaTrader Support Forum > NinjaScript Development Support > Indicator Development

Indicator Development Support for the development of custom indicators using NinjaScript.

Reply
 
Thread Tools Display Modes
Old 08-03-2012, 12:24 PM   #1
dkrumholz
Member
 
Join Date: Aug 2009
Location: Princeton NJ
Posts: 83
Thanks: 10
Thanked 0 times in 0 posts
Default Market Analyer vs Chart Indicator Differences

I have a chart with an indicator that exposes a value and draws an arrow under certain condiitons. The chart is linked with a market analyzer window that has a column for the same indicator. The problem is that the indiator on the chart and the indicator called by the market analyzer are returning different values.

I have determined that the problem is that the chart has a data series that can be told to only load n days of data. The market analyzer on the other hand can only be set to look back 256 bars or an infinite number of bars. So if I set the chart data series to 256 days and the indicator called by the analyzer to look back 256 bars, where each bar is one day, I can get the same values.

Shouldn't the market analyzer also be able to be set to only load n days of data? Without that setting one needs to adjust the chart to only have 256 bars of data. Is that correct? Am I overlooking an alternate solution that prevents the discrepancy?
dkrumholz is offline  
Reply With Quote
Old 08-03-2012, 01:18 PM   #2
NinjaTrader_JC
NinjaTrader Customer Service
 
NinjaTrader_JC's Avatar
 
Join Date: Mar 2012
Location: Denver, CO
Posts: 1,195
Thanks: 134
Thanked 181 times in 180 posts
Default

Hello dkrumholz,

The Market Analyzer, unlike a chart, is mainly used for real-time market scanning for multiple instruments, therefore a number of days to load would not be needed.

Yes, you could set the Maximum bars look back to 256 on each of the Market Analyzer and the Charting window.

The other options to check would is to check the Calculate on bar close is set to false if you are using the Market Analyzer as the indicator will be updated every tick.

http://www.ninjatrader.com/support/h...onbarclose.htm

Please note that exposing an indicator value that is not a plot would be used for access from other indicators or strategies.
http://www.ninjatrader.com/support/f...ead.php?t=4991


Please let me know if I can be of further assistance.
NinjaTrader_JC is online now  
Reply With Quote
Old 08-03-2012, 01:36 PM   #3
dkrumholz
Member
 
Join Date: Aug 2009
Location: Princeton NJ
Posts: 83
Thanks: 10
Thanked 0 times in 0 posts
Default

Since I am using the market analyzer for market scanning and I want the scan to match the chart that is linked - I think do need that setting. I don't understand how the market analyzer being used for real time scanning is justification for omitting that setting. I don't see how realtime scanning obviates the need for the setting. Can you explain how the one follows from the other? It doesn't yet make sense to me.
dkrumholz is offline  
Reply With Quote
Old 08-03-2012, 02:09 PM   #4
NinjaTrader_JC
NinjaTrader Customer Service
 
NinjaTrader_JC's Avatar
 
Join Date: Mar 2012
Location: Denver, CO
Posts: 1,195
Thanks: 134
Thanked 181 times in 180 posts
Default

Hello dkrumholz,

To start lets make sure you are getting the same values on each one. If you set Calculate on bar close and the Maximum bars look back to 256 on both the Market Analyzer, and the Chart does you indicator have the same value?

As for the Market Analyzer, you will want to use the right tool for the job, for example to look back at data for a specific number of day the best tool would be a chart. With that said, you still do have the option to set the Maximum number of bars to Infinite so you still can access to the full series so you can look back farther than just 256 bars.

http://www.ninjatrader.com/support/h...rslookback.htm
NinjaTrader_JC is online now  
Reply With Quote
Old 08-04-2012, 03:36 AM   #5
dkrumholz
Member
 
Join Date: Aug 2009
Location: Princeton NJ
Posts: 83
Thanks: 10
Thanked 0 times in 0 posts
Default

I must apologize. The setting is there - almost. I don't know why I keep overlooking it. The indicator when called from the market analyzer has a setting for number of bars to look back. Not the same as the chart which has a value set in days but if you work with a daily chart it happens to work out.

As a wish list item - the two settings should be changed to have identical units. The indicator when called from the market analyzer should probably have number of days to look back (like the chart's data series) instead of number of bars to look back.
dkrumholz is offline  
Reply With Quote
Old 08-06-2012, 10:32 AM   #6
NinjaTrader_Bertrand
NinjaTrader Customer Service
 
NinjaTrader_Bertrand's Avatar
 
Join Date: Sep 2008
Location: Germany
Posts: 22,404
Thanks: 252
Thanked 972 times in 955 posts
Default

Thanks much for your feedback dkrumholz, I've added this item to our product management enhancement tracking lists here.
NinjaTrader_Bertrand is offline  
Reply With Quote
Reply

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
significant chart differences nicknamed Charting 1 05-01-2012 08:33 AM
why does 'semicup' indicator show differently between data box and market analyer newstar20088 Market Analyzer 3 04-14-2011 10:49 AM
MA vs Chart differences.... domenech Market Analyzer 3 06-07-2010 09:58 AM
Chart differences vast524 Charting 8 01-13-2009 05:24 AM
Tick Chart Differences Kardinal Charting 6 08-14-2008 07:15 AM


All times are GMT -6. The time now is 11:45 AM.