I tried "Pivots(Data.PivotRange.Daily,20);" to no avail. It is telling me it cannot convert "NinjaTrader.Data.PivotRange" to "NinjaTrader.Data.IDataSeries". What is the IDataSeries value I can put in there in order for this to work? Thank you.
Announcement
Collapse
No announcement yet.
Partner 728x90
Collapse
NinjaTrader
Pivots
Collapse
X
-
Pivots
I am trying to call the Pivots indicator from within another indicator I am building to use the pivot points for some calculations, but I am having difficulty calling the indicator.
I tried "Pivots(Data.PivotRange.Daily,20);" to no avail. It is telling me it cannot convert "NinjaTrader.Data.PivotRange" to "NinjaTrader.Data.IDataSeries". What is the IDataSeries value I can put in there in order for this to work? Thank you.Josh P.NinjaTrader Customer ServiceTags: None
-
Please check out the methods signature provided by Intellisense:
Pivots(Data.IDataSeries input, int width)
This means you need to code something like:
Pivots(Input, 20).PivotRangeType = PivotRange.Daily; // extra code to change pivots type to daily
double val = Pivots(Input, 20).PP[0];
Note: the PivotRangeType is not supported yet as a parameter on the Pivots() method, that's why you'll need to the extra code line. We'll look into it and likely support it codewise by fall time frame
-
This method doesn't seem to work when you try to set two variables to two different range types.
Pivots(Input, 20).PivotRangeType = PivotRange.Daily; // extra code to change pivots type to daily
double val = Pivots(Input, 20).PP[0];
Pivots(Input, 20).PivotRangeType = PivotRange.Weekly;
double val2 = Pivots(Input, 20).PP[0];
I was playing around with various Print() throughout to see where it messes up and this is what I've found. The indicator does acknowledge the change in PivotRangeTypes, but it does not recognize that you are calling Pivots twice. Once with the first PivotRangeType and once with the second. It seems to ignore the second PivotRangeType change completely. It takes the Daily and just does both val and val2 on Daily.Josh P.NinjaTrader Customer Service
Comment
Latest Posts
Collapse
| Topics | Statistics | Last Post | ||
|---|---|---|---|---|
|
Started by Geovanny Suaza, 02-11-2026, 06:32 PM
|
0 responses
576 views
0 likes
|
Last Post
|
||
|
Started by Geovanny Suaza, 02-11-2026, 05:51 PM
|
0 responses
334 views
1 like
|
Last Post
|
||
|
Started by Mindset, 02-09-2026, 11:44 AM
|
0 responses
101 views
0 likes
|
Last Post
by Mindset
02-09-2026, 11:44 AM
|
||
|
Started by Geovanny Suaza, 02-02-2026, 12:30 PM
|
0 responses
553 views
1 like
|
Last Post
|
||
|
Started by RFrosty, 01-28-2026, 06:49 PM
|
0 responses
551 views
1 like
|
Last Post
by RFrosty
01-28-2026, 06:49 PM
|

Comment