The indicators I have developed do not show correct results when I change this parameter
Announcement
Collapse
No announcement yet.
Partner 728x90
Collapse
NinjaTrader
ticks per level
Collapse
X
-
Hello franki,
If you are asking how to specify this from AddVolumetric(), there is a parameter for this.
AddVolumetric(string instrumentName, Data.BarsPeriodType baseBarsPeriodType, int baseBarsPeriodTypeValue, Data.VolumetricDeltaType deltaType, int tickPerLevel)
If you are asking about using Volumetric bars in the code, there is a note on this in the help guide for GetMaximumVolume().
"For scenarios where Ticks per level is greater than 1, this method will return the lowest price - with Ticks per level known, the remaining prices in the result cell could be custom calculated if desired."
You can loop by the BarsPeriod.Value to loop by the TicksPerLevel
NinjaTrader.NinjaScript.BarsTypes.VolumetricBarsTy pe barsType = BarsArray[BarsInProgress].BarsType as
NinjaTrader.NinjaScript.BarsTypes.VolumetricBarsTy pe;
if (barsType == null)
return;
try
{
for (double rowPrice = High[0]; rowPrice >= Low[0]; rowPrice -= TickSize * BarsPeriod.Value)
{
double price;
Print("\r\nrowPrice: " + rowPrice);
Print("Delta for Close: " + barsType.Volumes[CurrentBar].GetDeltaForPrice(rowPrice));
Print("Bid for Close: " + barsType.Volumes[CurrentBar].GetBidVolumeForPrice(rowPrice));
Print("Ask for Close: " + barsType.Volumes[CurrentBar].GetAskVolumeForPrice(rowPrice));
}
}Chelsea B.NinjaTrader Customer Service
Latest Posts
Collapse
| Topics | Statistics | Last Post | ||
|---|---|---|---|---|
|
Started by CarlTrading, 03-31-2026, 09:41 PM
|
1 response
43 views
0 likes
|
Last Post
|
||
|
Started by CarlTrading, 04-01-2026, 02:41 AM
|
0 responses
21 views
0 likes
|
Last Post
by CarlTrading
04-01-2026, 02:41 AM
|
||
|
Started by CaptainJack, 03-31-2026, 11:44 PM
|
0 responses
30 views
1 like
|
Last Post
by CaptainJack
03-31-2026, 11:44 PM
|
||
|
Started by CarlTrading, 03-30-2026, 11:51 AM
|
0 responses
50 views
0 likes
|
Last Post
by CarlTrading
03-30-2026, 11:51 AM
|
||
|
Started by CarlTrading, 03-30-2026, 11:48 AM
|
0 responses
40 views
0 likes
|
Last Post
by CarlTrading
03-30-2026, 11:48 AM
|

Comment