Computing A Signal Variance in Real Time
28 Jul 2017The standard way to compute the variance of a data set is using the sqaure of the standard deviation. When we have scalar values
I already described in my previous blog post how to compute the mean in real time using the following algorithm at runtime:
This saves memory and is more elegent.
Similarly, we can compute the variance of a data set using another recursive algorithm:
Note that, to compute the variance, we also require to compute the mean.
References: