williams_fractals
Confirmed fractal highs and lows after Williams
williams_fractals
examples/site_showcase.rs// Confirmed fractal highs and lows after Williams (1995): a bar whose high (low) is strictly above (below) those of span bars on each side, confirmed span bars later; value is the latest up-fractal high, extra down_level the latest down-fractal low, published once both exist
// Defaults of "williams_fractals" (see the indicator reference)
let params = HashMap::from([
("span".to_string(), 2.0),
]);
let mut indicator = build_checked("williams_fractals", ¶ms)?;
for bar in &bars {
if let Some(output) = indicator.on_bar(bar) {
// output.value, output.extra[...], indicator.alerts()
}
}