The standard deviation is a widely used concept in statistics and it tells how much variation (spread or dispersion) is in the data set. It can be defined as the positive square root of the mean (average) of the squared deviations of the values from their mean.

To calculate the standard deviation one has to follow these steps:

#### Calculation of Standard Deviation

- First, find the mean of the data.
- Take the difference of each data point from the mean of the given data set (which is computed in step 1). Note that, the sum of these differences must be equal to zero or near to zero due to rounding of numbers.
- Now compute the square of the differences obtained in Step 2, it would be greater than zero, and it will be a positive quantity.
- Now add up all the squared quantities obtained in step 3. We call it the sum of squares of differences.
- Divide this sum of squares of differences (obtained in step 4) by the total number of observations (available in data) if we have to calculate population standard deviation ($\sigma$). If you want t to compute sample standard deviation ($S$) then divide the sum of squares of differences (obtained in step 4) by the total number of observations minus one ($n-1$) i.e. the degree of freedom. Note that $n$ is the number of observations available in the data set.
- Find the square root (also known as under root) of the quantity obtained in step 5. The resultant quantity in this way is known as the standard deviation (SD) for the given data set.

The sample SD of a set of $n$ observation, $X_1, X_2, \cdots, X_n$ denoted by $S$ is

\begin{aligned}

\sigma &=\sqrt{\frac{\sum_{i=1}^n (X_i-\overline{X})^2}{n}}; Population\, SD\\

S&=\sqrt{ \frac{\sum_{i=1}^n (X_i-\overline{X})^2}{n-1}}; Sample\, SD

\end{aligned}

The standard deviation can be computed from variance too.

The real meaning of the standard deviation is that for a given data set 68% of the data values will lie within the range $\overline{X} \pm \sigma$ i.e. within one standard deviation from the mean or simply within one $\sigma$. Similarly, 95% of the data values will lie within the range $\overline{X} \pm 2 \sigma$ and 99% within $\overline{X} \pm 3 \sigma$.

**Examples**

A large value of SD indicates more spread in the data set which can be interpreted as the inconsistent behaviour of the data collected. It means that the data points tend to be away from the mean value. For the case of smaller standard deviation, data points tend to be close (very close) to the mean indicating the consistent behavior of the data set.

The standard deviation and variance are used to measure the risk of a particular investment in finance. The mean of 15% and standard deviation of 2% indicates that it is expected to earn a 15% return on investment and we have a 68% chance that the return will be between 13% and 17%. Similarly, there is a 95% chance that the return on the investment will yield an 11% to 19% return.

Ajay GUptaHi,

The formula shown for Population Standard Deviation and Sample Standard Deviation has a typo error i.e. the sum of the deference’s of each data point from the mean is not squared.

Muhammad Imdad UllahThank you, Dear. Correction is made on square and summation too.