计算平均值、计算方差、计算平均方差、计算标准差。
例如,对于一个有六个数的数集2,3,4,5,6,8,其标准差可通过以下步骤计算:
计算平均值:
(2 + 3 + 4 + 5+ 6 + 8)/6 = 30 /6 = 5
计算方差:
(2 – 5)^2 = (-3)^2= 9
(3 – 5)^2 = (-2)^2= 4
(4 – 5)^2 = (-1)^2= 0
(5 – 5)^2 = 0^2= 0
(6 – 5)^2 = 1^2= 1
(8 – 5)^2 = 3^2= 9
计算平均方差:
(9 + 4 + 0 + 0+ 1 + 9)/6 = 24/6 = 4
计算标准差:
√4 = 2。