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
Getting a value to who in DataBox
Collapse
X
-
Getting a value to who in DataBox
How do I do this? I have a function in my strategy that does a calculation, and I would like for it to show up in the DataBox. Do I have to create an indicator in order for this to happen? It's just a function. Point me in the right direction please.Tags: None
-
imported post
Ok, this is my code generated from wizard. On my onBarUpdate() I have these lines of code:
double d = 0;
d = (((CCI(6)[0] - CCI(14)[0]) / (CCI(6)[1] - CCI(14)[1]))) * 100;
Value.Set(d);
Basically, just calculating percentage. I would like the value of "d" to show up in the DataBox. Right now, it's not working.
Comment
-
imported post
Ok, it's because I'm trying to access the data one bar ago for this calculation. The logs say "index out of bounds". Check the code below. So, what does that mean for me? There's plenty of bars on the chart. Does that mean that the indicator does not have access to those? Don't understand.
Comment
Latest Posts
Collapse
Topics | Statistics | Last Post | ||
---|---|---|---|---|
Started by ZenCortexCLICK, Today, 04:58 AM
|
0 responses
5 views
0 likes
|
Last Post Today, 04:58 AM | ||
Started by sidlercom80, 10-28-2023, 08:49 AM
|
172 responses
2,280 views
0 likes
|
Last Post
by sidlercom80
Today, 04:40 AM
|
||
Started by Irukandji, Yesterday, 02:53 AM
|
2 responses
18 views
0 likes
|
Last Post
by Irukandji
Today, 03:55 AM
|
||
Started by adeelshahzad, Today, 03:54 AM
|
0 responses
7 views
0 likes
|
Last Post
by adeelshahzad
Today, 03:54 AM
|
||
Started by Barry Milan, Yesterday, 10:35 PM
|
3 responses
13 views
0 likes
|
Last Post Yesterday, 11:58 PM |
Comment