And here is the test indicator code.
Announcement
Collapse
Looking for a User App or Add-On built by the NinjaTrader community?
Visit NinjaTrader EcoSystem and our free User App Share!
Have a question for the NinjaScript developer community? Open a new thread in our NinjaScript File Sharing Discussion Forum!
Have a question for the NinjaScript developer community? Open a new thread in our NinjaScript File Sharing Discussion Forum!
See more
See less
Partner 728x90
Collapse
NinjaTrader
Cumulative Delta not giving me expected results
Collapse
X
-
Cumulative Delta not giving me expected results
What am I missing here? I'm drawing the delta close below the candles here. I've highlighted the most dramatic case, but as you can see here the delta close is not matching the actual indicator. I'm using BarDelta vs Session and BidAsk DeltaType.
And here is the test indicator code.
1 PhotoTags: None
-
Hi, thanks for posting.
The scripts needs to update the Cumulative Delta in the 1 tick series (BarsInProgress == 1), and the Cumulative Delta you have on the chart needs to be set to "Bar".
Code:if (BarsInProgress == 0) { Draw.Text(this, "close" + CurrentBar, ""+ CD.DeltaClose[0], 0, Low[0] - 30); } else if (BarsInProgress == 1) { // We have to update the secondary series of the hosted indicator to make sure the values we get in BarsInProgress == 0 are in sync CD.Update(CD.BarsArray[1].Count - 1, 1); }
-ChrisLChris L.NinjaTrader Customer Service
-
Comment
Latest Posts
Collapse
Topics | Statistics | Last Post | ||
---|---|---|---|---|
Started by burtoninlondon, Today, 12:38 AM
|
0 responses
4 views
0 likes
|
Last Post Today, 12:38 AM | ||
Started by AaronKoRn, Yesterday, 09:49 PM
|
0 responses
12 views
0 likes
|
Last Post
by AaronKoRn
Yesterday, 09:49 PM
|
||
Started by carnitron, Yesterday, 08:42 PM
|
0 responses
11 views
0 likes
|
Last Post
by carnitron
Yesterday, 08:42 PM
|
||
Started by strategist007, Yesterday, 07:51 PM
|
0 responses
13 views
0 likes
|
Last Post Yesterday, 07:51 PM | ||
Started by StockTrader88, 03-06-2021, 08:58 AM
|
44 responses
3,982 views
3 likes
|
Last Post
by jhudas88
Yesterday, 06:59 PM
|
Comment