How to create a dynamic plot across subplots?

Hi everyone,

Each data point in the lower subplot comes from an estmation over a moving window of the data in the upper subplot. I would like to let the user move the gray shaded window above such that plotly automatically moves the gray dot in the subplot below.

I don’t know where to start. So no need for a complete answer, any hint as to where to start would be much appreciated.