pub fn cmo(data: &[f64], period: usize) -> Result<Vec<Option<f64>>>Expand description
Calculate Chande Momentum Oscillator (CMO).
Similar to RSI but uses sum of gains - sum of losses. Returns value between -100 and 100.
§Arguments
data- Price data (typically close prices)period- Number of periods
§Example
use finance_query::indicators::cmo;
let prices = vec![10.0, 11.0, 12.0, 11.0, 10.0];
let result = cmo(&prices, 3).unwrap();