pub struct ExtendedVolumeProfileEngine { /* private fields */ }Expand description
Extended volume profile over the last lookback bars.
Bins, POC and value area follow the rules of
super::volume_profile::VolumeProfileEngine: the window’s own range in num_bins equal
bins, each bar’s volume spread evenly over the bins it spans, the POC at the centre of the first
largest bin, a 70 % value area grown towards the larger neighbour. value is the POC. The full
profile with its value area, and a delta profile — buy minus sell volume per bin, split by the
close’s position in each bar’s range — come as ProfileArtifacts; runs of high- and
low-volume bins (at least 1.5x resp. at most 0.5x the mean bin volume by default) as
ZoneArtifacts.
A window without range produces no output. First output: with the lookback-th bar.
Indicator::reset clears the window.
Implementations§
Source§impl ExtendedVolumeProfileEngine
impl ExtendedVolumeProfileEngine
pub fn new(lookback: usize, num_bins: usize) -> Self
Sourcepub fn with_thresholds(self, hvn_multiplier: f64, lvn_multiplier: f64) -> Self
pub fn with_thresholds(self, hvn_multiplier: f64, lvn_multiplier: f64) -> Self
Overrides the default HVN (1.5x mean) / LVN (0.5x mean) classification multipliers.
Sourcepub fn on_intrabar_group(
&mut self,
group: &IntrabarGroup,
) -> Option<IndicatorOutput>
pub fn on_intrabar_group( &mut self, group: &IntrabarGroup, ) -> Option<IndicatorOutput>
Feeds a confirmed IntrabarGroup (a parent bar’s full ordered child-bar sequence),
recording each child individually instead of the aggregate parent bar alone — finer
intrabar volume distribution than Indicator::on_bar’s per-parent-bar granularity.
lookback then counts child-bar entries, not parent bars.
Trait Implementations§
Source§impl Indicator for ExtendedVolumeProfileEngine
impl Indicator for ExtendedVolumeProfileEngine
fn name(&self) -> &str
fn warmup_period(&self) -> usize
fn reset(&mut self)
fn on_bar(&mut self, bar: &Bar) -> Option<IndicatorOutput>
fn alerts(&self) -> Vec<IndicatorAlert>
Source§fn on_checked_bar(
&mut self,
bar: &Bar,
) -> Result<Option<IndicatorOutput>, BarValidationError>
fn on_checked_bar( &mut self, bar: &Bar, ) -> Result<Option<IndicatorOutput>, BarValidationError>
Indicator::on_bar.