Skip to main content

plus_dm_into

Function plus_dm_into 

Source
pub fn plus_dm_into(
    high: &[Float],
    low: &[Float],
    period: usize,
    output: &mut [Float],
) -> Result<PlusDmState, TechalibError>
Expand description

§Calculation of the PLUS_DM function

It stores the results in the provided output arrays and return the state PlusDmState.

§Input Arguments

  • high: A slice of Float representing the high prices.
  • low: A slice of Float representing the low prices.
  • period: The period for the calculation.

§Output Arguments

  • output: A mutable slice of Float where the calculated values will be stored.

§Returns

A Result containing a PlusDmState, or a TechalibError error if the calculation fails.