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
Any limit to number of plots in indicator?
Collapse
X
-
Any limit to number of plots in indicator?
Im getting really strange behavior when I add an 19th plot to my indicator. Its merging it on the cart with the 18th plot. I have tripple checked my code and I don't see anything I am doing wrong. When I comment out the 19th plot, it works fine, when I add it back in, its putting the values in the 18th plot. Very strange. Any limit I am running up against here?Tags: None
-
Hello ErikY,
There are no limits for plots, from the given description I could guess that you used a public property and for the 19th plot you have used the incorrect Value[index].
We would need to see the code you used to get a better idea of why that's not working.
I look forward to being of further assistance.JesseNinjaTrader Customer Service
Comment
-
Thanks s.kinra and Jesse.
Jesse, that was exactly what I suspected and triple checked it. You are correct on public properties. I went through all of my plots both in declarations and also in sate.setdefaults to see if I ddi anything funny, and I am not seeing anything at all.
I copied the code to another indicator and changed the index from 18 to 3 because that is how many there were on other indicator, and all works fine.
The indicator is massive so I don't know if I could post the entire indicator code, but would it be helpful if I posed the code for say index 17 and 18?
Comment
-
Hello ErikY,
It sounds like the indicator is potentially just using the public property or Value incorrectly somewhere in the code. There's not limit to plots so if you are running into something that is incorrect you would need to track that down in your logic.
As a comparable test you could make a new indicator with the same number of plots and then just set them all to specific values in OnBarUpdate with no other logic. That would show that its working and if its not you will have a sample to provide.
An alternative here is to use the indicator wizard to generate an indicator with that many plots, you can use the dialog to configure them. Once you generate it you can copy/paste the generated properties and other defaults for the plots over your existing code to make sure you have everything configured right.
Even in your existing script you could test this by commenting out the OnBarUpdate logic and then just set the plot to a value, if its the right value and shows up correctly then you can conclude the properties and plot are right and its your logic.
I look forward to being of further assistance.
JesseNinjaTrader Customer Service
Comment
Latest Posts
Collapse
Topics | Statistics | Last Post | ||
---|---|---|---|---|
Started by WHICKED, 03-27-2024, 12:33 PM
|
4 responses
41 views
0 likes
|
Last Post Today, 12:28 AM | ||
Started by f.saeidi, Today, 12:12 AM
|
0 responses
3 views
0 likes
|
Last Post
by f.saeidi
Today, 12:12 AM
|
||
Started by Conall, Today, 12:06 AM
|
0 responses
5 views
0 likes
|
Last Post
by Conall
Today, 12:06 AM
|
||
Started by proptradingshop, 03-21-2024, 09:50 AM
|
6 responses
27 views
0 likes
|
Last Post Today, 12:02 AM | ||
Started by mly916, Yesterday, 09:48 PM
|
1 response
12 views
0 likes
|
Last Post Yesterday, 11:54 PM |
Comment