kestrel-chartkitv0.43.0

← All examples

pair_spread

Residual z-score of the spread between a close series and a reference series, with hedge ratio, spread, mea…

pair_spread

examples/site_showcase.rs
// Residual z-score of the spread between a close series and a reference series, with hedge ratio, spread, mean and deviation
let mut indicator = build_pair_checked("pair_spread", &params)?;
// The bars of the two series are paired by timestamp.
let outputs = run_pair_batch(indicator.as_mut(), &bars, &reference);

Not yet verified: no independent second implementation yet.

It reads two series, the bars and a reference series, and the demo is one share; it is not drawn here.

  • Other input kinds
  • unit: Ratio