iirc, @Jameson Lopp had something like this in a blog post.
You might be thinking of https://blog.lopp.net/bitcoin-block-time-variance/
Exactly that. Thank you.