Announcement
Collapse
No announcement yet.
Partner 728x90
Collapse
NinjaTrader
Simple Pivot Indicator Not Working
Collapse
X
-
Simple Pivot Indicator Not Working
Hello world. I've attached this simple indicator that I'm working on. For some reason it won't load the data. I use it on a Range bar chart. It's purpose is to take data from multi-time frame (dailyBars). Please look at attached and help if possible.Tags: None
-
Hello ginx10k,
Thank you for your post.
Your issue is that you're checking if the secondary series has at least BarsRequiredToPlot bars loaded before plotting:
if (CurrentBars[0] < BarsRequiredToPlot || CurrentBars[1] < BarsRequiredToPlot)
return;
Since this is a 1 day series, you'd need to have at least 20 days of data loaded for this to plot anything.
Try changing that to this:
if (CurrentBars[0] < BarsRequiredToPlot || CurrentBars[1] < 1)
return;
You should then see it plot if at least 1 day of data is loaded on the chart.
Please let us know if we may be of further assistance to you.
-
Hello ginx10k,
Thank you for your reply.
I'm attaching the script with the change I made and I can confirm this is working on my end. Please see the screenshot below:
I would suggest comparing your script with the one with my change below to see what may be different between the two.
Please let us know if we may be of further assistance to you.
- Likes 1
Comment
Latest Posts
Collapse
| Topics | Statistics | Last Post | ||
|---|---|---|---|---|
|
Started by cmoran13, 04-16-2026, 01:02 PM
|
0 responses
43 views
0 likes
|
Last Post
by cmoran13
04-16-2026, 01:02 PM
|
||
|
Started by PaulMohn, 04-10-2026, 11:11 AM
|
0 responses
26 views
0 likes
|
Last Post
by PaulMohn
04-10-2026, 11:11 AM
|
||
|
Started by CarlTrading, 03-31-2026, 09:41 PM
|
1 response
163 views
1 like
|
Last Post
|
||
|
Started by CarlTrading, 04-01-2026, 02:41 AM
|
0 responses
98 views
1 like
|
Last Post
by CarlTrading
04-01-2026, 02:41 AM
|
||
|
Started by CaptainJack, 03-31-2026, 11:44 PM
|
0 responses
158 views
2 likes
|
Last Post
by CaptainJack
03-31-2026, 11:44 PM
|

Comment