If we look at the 7 or 14 day average of new infections, we are always lagging behind. I was wondering: can we do better? In essence, the issue with a normal 7-day average is that it gives equal weight to the values for all 7 days, when the last day is actually a much better predictor for the future, than the first day.
Let's model the daily new infections as a function f, where $f(n)$ is the new infections occurring on day n. We define it as $f(n) = f(n-1) r(n)$. The value $r(n)$ is the growth rate on day n. It is defined as $r(n) = r(n-1) + x$, where $x$ is a random real number that follows a normal distribution. In other words, the daily new infections are computed from the growth rate and the previous day, and the growth rate each day will randomly go down or up compared to the previous day. We can also add some random noise $y$ directly to $f$.
Given the data for the previous days, we can calculate which are the values for the next few days that best fit the model.
I am sure that something along these lines must already exist in statistics. Can someone point me to it?