Find the past windows whose shape is nearest the latest window, and show what followed each of them. Foresight does not extrapolate a level: it lays the past continuations over the present as a fan, with a median and a band. Patternode matches shapes from its tree of segments; this sketch uses a plain shape distance on one synthetic series.
The whole history. Drag to move now
Nearest analogues
Only data before now is used: a past window counts only if what followed it had finished before the latest window began. Shape distance compares the windows after removing level and scale, so a match can sit anywhere in the history. Move now back in time to see what actually happened beside the fan.