since the BlockVolume indicator seems handy to get a greater insight into volume movement, I thought about implementing it into some scripts and my chart setup. Though it turns out that it doesn't plot on TickReplay enabled charts, and some of my indicators require TickReplay enabled.
Is there a way to have BlockVolume and Tick Replay Indicators at the same time?
Secondly, (when not having TickReplaya enabled) the genuine BlockVolume Indicator, changes it's values after reloading the chart and after each reload only shows values for the last 30 bars or so. I have some screenshots attached.
The lowest indicator is a test scripts with the following key elements.:
private BlockVolume BlockVolIndicator1;
else if (State == State.Configure)
{
AddDataSeries(Data.BarsPeriodType.Tick, 1);
}
else if (State == State.DataLoaded)
{
BlockVolValues = new Series<double>(this);
BlockVolIndicator1 = BlockVolume(5, CountType.Volume);
}
}
protected override void OnBarUpdate()
{
if (BarsInProgress == 0){
if (CurrentBar != activeBar){
BlockVolValues[1] = BlockVolIndicator1[1];
BlockVolumeBars[1] = BlockVolValues[1];
activeBar = CurrentBar;
}
BlockVolumeBars[0] = BlockVolValues[0];
}
}
// ----Alternatively: ----
protected override void OnBarUpdate()
{
BlockVolumeBars[0] = BlockVolIndicator1[0];
}
My question is, is that just the way it is and the BlockVolume Indicator is designed that way or am I doing something wrong? If so, I would love to know how to solve all the described issues.
Greetings,
Sebastian

Comment