Standard deviation
The standard deviation is a measure of how spread out a set of numbers are.
The standard deviation of a set of numbers is the square root of their variance. Variance is usually denoted by σ2 and the standard deviation by σ, and:
σ2 = 1/n Σ(xi - μ)2
where xi is one of n numbers and
μ is the arithmetic mean all n numbers x.
Variance as a measure of risk
The most common use of the standard deviation in finance is to measure the risk of holding a security or portfolio. We first need the expected price:
E[S] =ΣSip(Si)
where S is a price
and p(Si) is the probability that S will be the actual price.
Denoting the variance of S, Var(S):
Var(S) = Σ(Si - E[S])2p(Si)
Var(S) is a measure of volatility. Its square root (the standard deviation) is the most widely used measure of volatility.
To use continuous times and prices replace the sums above with integrals.