σ2=E[(X−μ)2] where μ=E[X] If we have equally likely N data points, this is equivalent to: σ2=N1∑i=1n(Xi−μ)2