pub struct AccDistEngine { /* private fields */ }Expand description
Accumulation/Distribution Line (A/D): a running total of money-flow volume.
Each bar adds MFM * volume with the money-flow multiplier of CmfEngine,
((close - low) - (high - close)) / (high - low) (0 for a range below 1e-8). A close in
the middle of its range therefore adds nothing, however large the volume.
First output: with the first bar. Indicator::reset returns the total to zero.
Implementations§
Source§impl AccDistEngine
impl AccDistEngine
Trait Implementations§
Source§impl Clone for AccDistEngine
impl Clone for AccDistEngine
Source§fn clone(&self) -> AccDistEngine
fn clone(&self) -> AccDistEngine
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for AccDistEngine
impl Debug for AccDistEngine
Source§impl Default for AccDistEngine
impl Default for AccDistEngine
Source§impl Indicator for AccDistEngine
impl Indicator for AccDistEngine
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>
Validates a bar before forwarding it to
Indicator::on_bar.Auto Trait Implementations§
impl Freeze for AccDistEngine
impl RefUnwindSafe for AccDistEngine
impl Send for AccDistEngine
impl Sync for AccDistEngine
impl Unpin for AccDistEngine
impl UnsafeUnpin for AccDistEngine
impl UnwindSafe for AccDistEngine
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more