pub struct HiResVolumeFlowEngine { /* private fields */ }Expand description
Streaming high-resolution volume flow engine.
Implementations§
Source§impl HiResVolumeFlowEngine
impl HiResVolumeFlowEngine
pub fn new(window_len: usize) -> Self
pub fn reset(&mut self)
Sourcepub fn on_bar_with_aggressor(
&mut self,
bar: &Bar,
aggressor: AggressorVolume,
) -> HiResVolumeFlowOutput
pub fn on_bar_with_aggressor( &mut self, bar: &Bar, aggressor: AggressorVolume, ) -> HiResVolumeFlowOutput
High-resolution path: feeds a bar with directly known aggressor volume (e.g. aggregated from trade-tape data).
Sourcepub fn on_intrabar_group(
&mut self,
group: &IntrabarGroup,
) -> HiResVolumeFlowOutput
pub fn on_intrabar_group( &mut self, group: &IntrabarGroup, ) -> HiResVolumeFlowOutput
High-resolution path: feeds a confirmed IntrabarGroup (a parent bar’s full ordered
child-bar sequence), summing each child’s own OHLC-inferred delta instead of applying the
heuristic once to the aggregate parent bar — preserves the intrabar price path the
aggregate alone loses.
Sourcepub fn on_bar_estimated(&mut self, bar: &Bar) -> HiResVolumeFlowOutput
pub fn on_bar_estimated(&mut self, bar: &Bar) -> HiResVolumeFlowOutput
Fallback path: OHLC-inferred estimate when no direct aggressor or intrabar data is
available, explicitly tagged as such via BarQuality::volume_available staying accurate
but the estimate not being a genuine tick-level measurement.
Trait Implementations§
Source§impl Indicator for HiResVolumeFlowEngine
impl Indicator for HiResVolumeFlowEngine
Source§fn on_bar(&mut self, bar: &Bar) -> Option<IndicatorOutput>
fn on_bar(&mut self, bar: &Bar) -> Option<IndicatorOutput>
Delegates to the OHLC-estimated fallback path; use
HiResVolumeFlowEngine::on_bar_with_aggressor or
HiResVolumeFlowEngine::on_intrabar_group directly for the high-resolution paths, which
this trait’s single-Bar signature cannot express.
fn name(&self) -> &str
fn reset(&mut self)
fn alerts(&self) -> Vec<IndicatorAlert>
fn warmup_period(&self) -> usize
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.