Add(PeriodType.Day,1);
......
if (BarsInProgress == 0)
{
Print("bars in progress == 0 " + Time[0]); // this works
}
if (BarsInProgress == 1)
{ // for daily data
Print("Bars in progress == 1 " + Time[0]); // this doesnt work
}
Announcement
Collapse
No announcement yet.
Partner 728x90
Collapse
NinjaTrader
BarsinProgress with Daily
Collapse
X
-
BarsinProgress with Daily
I am trying to add a daily time frame to my indicator (probably running on 5-15min bars) but for some reason whenever I call barsinprogress ==1, I never get any results. I am loading 20 days of data on the chart. here is the code
any ideasCode:Tags: None
-
Hello,
Most indicators will not start calculating until after 20 bars have been calculated. Try expanding the number of days back to see if you get it to run then.
Also, the indicator will not run until all data is loaded.
Who is your data feed provider and also what is the primary data series?
I look forward to assisting you further.BrettNinjaTrader Product Management
-
its weird b/c I can get the 2nd time series to work if I change it to 60 mins 60, or 1440, but not a daily series.
I but in the contion
if (CurrentBar > 60)
but still I get 0.
I tried multiple instruemnts/data series and nothing. Load 50days worth of data.
Does it have anything to do with calling the
Add(PeriodType.Day,1);
is that the right notation
Comment
-
snap... I didnt have daily bars loaded. I thought that ninja made daily bars from min but I guess not. Problem solved thanks to kinetic. My data is on the other computer.. bah!
Thanks for the help though
Comment
Latest Posts
Collapse
| Topics | Statistics | Last Post | ||
|---|---|---|---|---|
|
Started by Hwop38, 05-04-2026, 07:02 PM
|
0 responses
164 views
0 likes
|
Last Post
by Hwop38
05-04-2026, 07:02 PM
|
||
|
Started by CaptainJack, 04-24-2026, 11:07 PM
|
0 responses
317 views
0 likes
|
Last Post
by CaptainJack
04-24-2026, 11:07 PM
|
||
|
Started by Mindset, 04-21-2026, 06:46 AM
|
0 responses
245 views
0 likes
|
Last Post
by Mindset
04-21-2026, 06:46 AM
|
||
|
Started by M4ndoo, 04-20-2026, 05:21 PM
|
0 responses
350 views
0 likes
|
Last Post
by M4ndoo
04-20-2026, 05:21 PM
|
||
|
Started by M4ndoo, 04-19-2026, 05:54 PM
|
0 responses
179 views
0 likes
|
Last Post
by M4ndoo
04-19-2026, 05:54 PM
|

Comment