You are on page 1of 7

Prof.

Thistleton

STA100 Statistical Methods

Lecture 4

Text Sections: Chapter 3 Sections 2 Computing Formula for Standard Deviation


So far we have seen how to describe a data set with just a few numbers: the mean and the median tell you where the data are centered and provide an insight to the data set with just one number. If you also know the standard deviation or the Inter-Quartile Range (IQR) you know how spread out the data are. As a reminder, suppose you have the following toy data set, and assume the data come from a sample (not the whole population): 100 112 121 95 97 as

You can easily calculate the sample mean,

(1)

Note a few things: weve used the symbol x bar since our data are drawn from a sample. If they had come from a population we would have used the Greek letter or mu. Also, since they come from a sample we have denoted the number of data points (the sample size) as little or lower case n. Finally, just as our text book does, Ive used the Greek letter upper case sigma or to indicate that we are adding some numbers up. What we are saying is that we have several numbers where the first is a 100, the second is 112, etc. A compact way to write this which clearly indicates which number is first, second, all the way to fifth is to say . Then since these are all individual data points from the variable write sum of the xs as . Greek letter sigma for sum.

Some people like to draw a dot plot showing the data on a horizontal scale: o o 80 90 o 100 o 110 o 120

If you draw in a small triangle under the line at the point 105 you can see that the (arithmetic) mean shows where a collection of numbers would balance or if you prefer has its center of mass. (Just think of kids on a see-saw). Now when we try to see how spread out the data are by calculating the standard deviation. Remember that to do this we calculate the mean (105) and then calculate the deviations, etc. Deviations2 (100-105)2 = (-5)2 = 25 (112-105)2 = (7)2 = 49 (121-105)2 = (16)2 = 256 (95-105)2 = (-10)2 = 100 (97-105)2 = (-8)2 = 64 494

sums

Data points, x 100 112 121 95 97 525

Deviations, 100-105 = -5 112-105 = 7 121-105 = 16 95-105 = -10 97-105 = -8 0

Once we add up all the squared deviations we take their average. As we noted before, some books at this point just divide by the number of data points, . Our book (and many others) divide by when the data come from a sample. They do this for the following reason. Remember that we usually form a sample because we cant get to all the data in the population. If you would like to know the average number of text messages sent by a 12 year old each day you cant get this info for all kids in America (not even Verizon can do this!) but will have to find a sample of, say, 100 kids and work from that. Dividing by tends to underestimate the true population variability, so we boost it a little by dividing by a little less, We can be more technical about this later. Thus the sample variance,

And the sample standard deviation (average deviation)

The Computational Formula


There is a formula that many people find easier to work with. A little algebra shows that you can calculate the sum of the squares as follows:

We can set up a table for this as well. First notice that you need to square all the add them up ( , and also add up all the terms themselves . Data points, x 100 112 121 95 97 sums This gives us Data points squared, 10000 12544 14641 9025 9409

terms and then

And so

See if you can reproduce these tables in your spreadsheet.

Chebyshev's Theorem.
Pafnuty Chebyshev was an 19th century Russian mathematician who is probably most famous for the following idea. Given any set of numbers you can think of, the standard deviation gives us a way of organizing the data in our mind. Consider the following data, expressed as a dot plot.

o o o o o o ------------------------------------------------------------------------------------------------------5 10 15 20 25 30 35 40 45 50 55 60 65 70 We can calculate the mean as

Put a marker on your graph at

Now calculate the standard deviation by filling in the missing figures in the table:

10 25 30 40 45 55 sums

100

1600 3025

And obtain

Now start to orient your data set by putting little markers one, two and three standard deviations away from the mean to each side. This is just like walking one, two, or three yards in either direction to mark out a garden. This gives us

If you mark your dotplot with these numbers you should see that o 10 o 25 o 30 o 40 o 45 o 55

15

20

35

50

60

65

70

Four of your numbers (25, 30, 40, and 45) lie between 18.22406 and 50.10927 All of your numbers lie between 2.281456 and 66.05188 Chebyshev told us that this isnt a coincidence. Heres what is always true: if you have a collection of numbers you are guaranteed to see At least 75% (3/4) of your data within 2 standard deviations of the mean At least 89% (8/9) of your data within 3 standard deviations of the mean At least 93.75% (15/16) of your data within 4 standard deviations of the mean. In general, you will see at least

Of your data within standard deviations of the mean. Note: You will probably see more. This is a worst case scenario.

Why do we care?

If I told you that I had a data set with a mean of 100 and a standard deviation of 15 (this is true for a certain type of IQ data) and if I then told you I knew someone with an IQ of 180 you could reason as follows: According to our friend Pafnuty, at least 75% of all people have an IQ between 70 and 130 (do you see that 70 = 100-2*15 and 130 = 100+2*15?) at least 89% of all people have an IQ between 55 and 145 (why?) at least 93.75% of all people have an IQ between 40 and 160 (why?) at least 96% of all people have an IQ between 25 and 175 (Please note that this is a little silly at this point- weve pushed the IQ idea too far.) So an IQ of 180 is really quite high.

The Normal Distribution


The Normal Distribution, =100, 0.03 =15

0.025

0.02

0.015

0.01

0.005

25

40

55

70

85

100

115

130

145

160

175

IQ data tend to have the distribution shown in the histogram above. This is called the Normal or Gaussian distribution and has a characteristic bell shape. Many real world data sets have this shape.

As you can see Chebyshev is really very conservative. There is an Empirical Rule in our text that tells us, when data are normally distributed: Approximately 68.27% of data will lie within one standard deviation of the mean (between 85 and 115 above). Approximately 95.45% of data will lie within one standard deviation of the mean (between 70 and 130 above). Approximately 99.73of data will lie within one standard deviation of the mean (between 55 and 145 above). So thats pretty much the whole show. Using the normal distribution we will later compute that the chances that someone randomly selected from the population has an IQ as high as 180 are actually 1 in 20,741,279 (if you believe the model).

You might also like