![]() |
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
|
|||||||
| Strategy Development Support for the development of custom automated trading strategies using NinjaScript. |
![]() |
|
|
Thread Tools | Display Modes |
|
|
#1 |
|
Senior Member
Join Date: Jun 2008
Location: Hong Kong
Posts: 214
Thanks: 0
Thanked 0 times in 0 posts
|
Hello
I have been getting strange discrepancies with the chart value of the ADX indicator and its output value on a running strategy (This happens at the start of a session not during the session, also, this doesn't happen all the time.... only 3 times so far) All other indicators (I use altogether 5 other indicators) show correct values in both the output and on my chart. To solve the problem I have had to Repair and Reset the DB, shut down NT and restart. Then all chart values and script output values the same. Obviously this is not ideal, so would anyone have thoughts on why I would be experiencing this problem, and can it be resolved? Thanks in advance
Last edited by John833; 12-17-2008 at 03:38 AM.
|
|
|
|
|
|
#2 |
|
NinjaTrader Customer Service
Join Date: Sep 2008
Location: Germany
Posts: 22,413
Thanks: 252
Thanked 976 times in 959 posts
|
Hi John833, please review these tips for improving performance - http://www.ninjatrader-support.com/H...rformanceTips1
Did you have any power outages or disconnects that could have impacted your database integrity? Thanks!
Bertrand
NinjaTrader Customer Service |
|
|
|
|
|
#3 |
|
Senior Member
Join Date: Jun 2008
Location: Hong Kong
Posts: 214
Thanks: 0
Thanked 0 times in 0 posts
|
Thanks Bertrand, I have already seen the performance website, and everything checks out ok.
No I haven’t had any power outages or have done anything different to the PC. Its concerning as there seems to be no reason why this happens…. Have you had any other experience of this? |
|
|
|
|
|
#4 |
|
NinjaTrader Customer Service
Join Date: Sep 2008
Location: Germany
Posts: 22,413
Thanks: 252
Thanked 976 times in 959 posts
|
Hi John833,
Which datafeed are you running? Does it happen under a lot of load on the PC, you may have to reduce the charts open or applications running to see if it makes a difference. If this is reproducible for you, we would appreciate you sending the needed steps to generate the issue to support at ninjatrader dot com, so we can look into it. Thanks!
Bertrand
NinjaTrader Customer Service |
|
|
|
|
|
#5 |
|
Senior Member
Join Date: Jun 2008
Location: Hong Kong
Posts: 214
Thanks: 0
Thanked 0 times in 0 posts
|
Hi Bertrand
My data feed is from my broker IB. (But when this problem occurs with the ADX indicator, all my other indicators are functioning fine) I use a new (3mth old) hi-spec pc 4Gb ram etc, and this only runs IB and NT, nothing else (except Norton360). CPU and RAM usage rarely go above 65%. The problem is that its not reproducible, so I have no idea where its coming from… Have you had any stability issues with the ADX indicator?
Last edited by John833; 12-17-2008 at 07:33 AM.
|
|
|
|
|
|
#6 |
|
NinjaTrader Customer Service
Join Date: Sep 2008
Location: Germany
Posts: 22,413
Thanks: 252
Thanked 976 times in 959 posts
|
Hi, none that I'm aware of. Your setup is sound - if you wish send in your logs and we take a look if something is suspicious.
Bertrand
NinjaTrader Customer Service |
|
|
|
|
|
#7 |
|
Senior Member
Join Date: Jun 2008
Location: Hong Kong
Posts: 214
Thanks: 0
Thanked 0 times in 0 posts
|
ok, I'll do that when it happens again, everything has been reset so I don't have any logs at the moment...
Thanks for your help |
|
|
|
|
|
#8 |
|
NinjaTrader Customer Service
Join Date: Sep 2008
Location: Germany
Posts: 22,413
Thanks: 252
Thanked 976 times in 959 posts
|
You're welcome, please do...
Bertrand
NinjaTrader Customer Service |
|
|
|
|
|
#9 |
|
Senior Member
Join Date: Jun 2008
Location: Hong Kong
Posts: 214
Thanks: 0
Thanked 0 times in 0 posts
|
Bertrand, this is what I have discovered with the ADX anomaly.
After repairing and resetting the DB, when I load up the chart and have the script running, the ADX value in the output is exactly the same as the ADX value on the chart, however if I reload historical data, the indicator values of the ADX changes… If I reset and repair the DB then the ADX values fall back into place…. Any thought on why this would happen? |
|
|
|
|
|
#10 |
|
NinjaTrader Customer Service
Join Date: Sep 2008
Location: Germany
Posts: 22,413
Thanks: 252
Thanked 976 times in 959 posts
|
Hi John833,
Thanks for reporting back your findings - please try to remove the 'CalculateOnBarClose' setting from your indicator file you call in your strategy and let me know if it improves your situation. Thanks!
Bertrand
NinjaTrader Customer Service |
|
|
|
|
|
#11 |
|
Senior Member
Join Date: Jun 2008
Location: Hong Kong
Posts: 214
Thanks: 0
Thanked 0 times in 0 posts
|
do you mean the ADX file, sorry I don't quite follow...
|
|
|
|
|
|
#12 |
|
NinjaTrader Customer Service
Join Date: Sep 2008
Location: Germany
Posts: 22,413
Thanks: 252
Thanked 976 times in 959 posts
|
Yes, please change it in the indicator you call from the strategy to diplay it on the chart...
Bertrand
NinjaTrader Customer Service |
|
|
|
|
|
#13 |
|
Senior Member
Join Date: Jun 2008
Location: Hong Kong
Posts: 214
Thanks: 0
Thanked 0 times in 0 posts
|
Bertrand
I have the standard ADX indicator file (the one that comes with NT) open, but I don't see a 'CalculateOnBarClose' statement? |
|
|
|
|
|
#14 |
|
NinjaTrader Customer Service
Join Date: Sep 2008
Location: Germany
Posts: 22,413
Thanks: 252
Thanked 976 times in 959 posts
|
Hi John,
Thanks for checking - then you should be fine from that angle...please also check your 'Display update interval' in the Chart properties and set it to 0 for testing this issue. Another idea would be to create a very simple strategy that only calls the ADX with the Add() and then Print() out this value to the output window to compare with the chart.
Bertrand
NinjaTrader Customer Service |
|
|
|
|
|
#15 |
|
Senior Member
Join Date: Jun 2008
Location: Hong Kong
Posts: 214
Thanks: 0
Thanked 0 times in 0 posts
|
ok I've set the interval to 0, and reloaded the chart, and the discrepancy is even more pronounced....
I already have ADX in the output from my strategy, but what I am concerned about is why am I seeing different values on the chart? It also leads to the question is the value that I am using in my script accurate and the chart inaccurate, or visa versa? All I am certain of is that once the DB is repaired and reset, values are the same, as soon as you reload the chart, the values change. Do you think this can this be resolved? |
|
|
|
![]() |
| Thread Tools | |
| Display Modes | |
|
|
Similar Threads
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| Discrepancies and lack of functionality. | bsamani | General Programming | 6 | 12-19-2008 07:02 AM |
| Print to Output | heech | Strategy Development | 3 | 11-15-2008 07:41 PM |
| Indicator: Using custom events to output the current Level II data book | NinjaTrader_Josh | Reference Samples | 0 | 03-04-2008 11:40 AM |
| Indicator output is different when invoked by strategy | zoltran | Strategy Development | 14 | 12-26-2007 07:07 AM |
| indicator output double available to a strategy | gluebunny | Strategy Development | 1 | 12-09-2007 02:49 AM |