# MA Soc: Lab Materials Week 7

## Week 7 Lab

## Spreadsheets and the standard deviation

Spreadsheets are occasionally very useful for manipulating data
and presenting numbers. They have a completely different way of
working from Stata, however. You can enter text, numbers and
*formulas* in the cells. The formulas can be simple (e.g.
`=5+6`

, which will display `11`

in the
cell) or arbitrarily complex (e.g. `=A1+A2`

, which
adds the values of two other cells;
`=normsdist((A1-B1)/B2)`

which returns the area of the
normal distribution to the right of the value in cell A1, for a
distribution with a mean of the value in cell B1, and a standard
deviation in cell B2).

### Exercise 1: Calculating a Standard deviation

If we have the following data about 10 people (minutes spent in
domestic work per day), how do we calculate the standard deviation:

1: 44
2: 36
3: 41
4: 36
5: 46
6: 49
7: 43
8: 44
9: 41
10: 54

These are the Xs, i.e. X_{1} to X_{10}
The steps are as follows:
- Enter the data in a spreadsheet in a single column
- Calculate the total at the bottom of the column (
`=sum(...)`

)
- Calculate the mean (total divided by 10) -- this is X-bar
- In the next column calculate the deviation (X
_{i} minus X-bar)
- In the next column calculate the squared deviations, (X
_{i} minus X-bar)^{2}
- Sum the squared deviations
- From these calculate the standard deviation, using the formula sheet