part of Course 137 Signal Processing Techniques

It's often useful to take a signal and shift and scale it so that it has a particlar mean and variance. For a mean of 0 and a variance of 1, this is known as standardization or Z-score normalization.

During the process, we end up working with the square root of the variance, the standard deviation. For a signal, s having a mean of μ_s and a standard deviation of σ_s, you can transform it to a signal z having a mean of 0 and a standard deviation of 1 with
z = (s - μ_s) / (σ_s + ε),
where ε is a small number, say 10^-6 or 10^-10, that prevents divide-by-zero errors in the rare cases where &sigma_s; is zero.

That in turn can be transformed to a signal t having any μ_t and σ_t with
t = z * σ_t + μ_t