dpo
Detrended Price Oscillator
dpo
examples/site_showcase.rs// Detrended Price Oscillator
// Defaults of "dpo" (see the indicator reference)
let params = HashMap::from([
("period".to_string(), 21.0),
]);
let mut indicator = build_checked("dpo", ¶ms)?;
for bar in &bars {
if let Some(output) = indicator.on_bar(bar) {
// output.value, output.extra[...], indicator.alerts()
}
}