2Statistics Topics left Standard deviation – a recapCumulative frequency- medians, quartiles IQR, deciles, percentiles and box whisker plotsHistogramsRandom variables- probability distributions, expectationBinomial distributionNormal distribution
3This symbol means the total of all the x values The mean is the most widely used average in statistics. It is found by adding up all the values in the data and dividing by how many values there are.Notation: If the data values are , then the mean isThis symbol means the total of all the x valuesThis is the mean symbolNote: The mean takes into account every piece of data, so it is affected by outliers in the data. The median is preferred over the mean if the data contains outliers or is skewed.
4Mean If data are presented in a frequency table: then the mean is ValueFrequency…then the mean is
5MeanExample: The table shows the results of a survey into household size. Find the mean size.Household size, xFrequency, f1202283254195166x × f205675768036TOTALTo find the mean, we add a 3rd column to the table.Mean = 343 ÷ 114 = 3.01
6Standard deviationThere are three commonly used measures of spread (or dispersion) – the range, the inter-quartile range and the standard deviation.The standard deviation is widely used in statistics to measure spread. It is based on all the values in the data, so it is sensitive to the presence of outliers in the data.The variance is related to the standard deviation:variance = (standard deviation)2Note: In the MEI S1 syllabus, these quantities are referred to as the mean squared deviation (msd) and the root mean squared deviation (rmsd). This is to distinguish them from the sample variance and the sample standard deviation.The following formulae can be used to find the variance and s.d.
7Standard deviationExample: The mid-day temperatures (in ˚C) recorded for one week in June were: 21, 23, 24, 19, 19, 20, 21First we find the mean:˚C212324243919-220-11So variance = 22 ÷ 7 = 3.143So, s.d. = 1.77 ˚C (3 s.f.)Total:
8Standard deviationThere is an alternative formula which is usually a more convenient way to find the variance:Therefore, and
9Standard deviationExample (continued): Looking again at the temperature data for June: 21, 23, 24, 19, 19, 20, 21We know that˚CAlso, = 3109So,˚CNote: Essentially the standard deviation is a measure of how close the values are to the mean value.
10Calculating standard deviation from a table When the data is presented in a frequency table, the formula for finding the standard deviation needs to be adjusted slightly:Example: A class of 20 students were asked how many times they exercise in a normal week.Find the mean and the standard deviation.Number of times exercise takenFrequency51324
11Calculating standard deviation from a table No. of times exercise taken, xFrequency, f51324x × fx2 × f310201236832525TOTAL:The table can be extended to help find the mean and the s.d.
12Calculating standard deviation from a table If data is presented in a grouped frequency table, it is only possible to estimate the mean and the standard deviation. This is because the exact data values are not known.An estimate is obtained by using the mid-point of an interval to represent each of the values in that interval.Example: The table shows the annual mileage for the employees of an insurance company.Estimate the mean and standard deviation.Annual mileage, xFrequency0 ≤ x < 500075000 ≤ x < 10,0001810,000 ≤ x < 15,0001415,000 ≤ x < 20,000420,000 ≤ x < 30,0002
13Calculating standard deviation from a table MileageFrequency, fMid-point, xf × xf × x20 – 5000625001500037,500,0005000 – 10,000177500127,500956,250,00010,000 – 15,0001412,500175,0002,187,500,00015,000 – 20,000517,50087,5001,531,250,00020,000 – 30,000325,00075,0001,875,000,000TOTAL , ,587,500,000milesmiles
14Notes about standard deviation Here are some notes to consider about standard deviation.In most distributions, about 67% of the data will lie within 1 standard deviation of the mean, whilst nearly all the data values will lie within 2 standard deviations of the mean.Values that lie more than 2 standard deviations from the mean are sometimes classed as outliers – any such values should be treated carefully.Standard deviation is measured in the same units as the original data. Variance is measured in the same units squared.Most calculators have built-in functions which will find the standard deviation for you. Learn how to use this facility onyour calculator.
15Examination style question Examination style question: The ages of the people in a cinema queue one Monday afternoon are shown in the stem-and-leaf diagram:Explain why the diagram suggests that the mean and standard deviation can be sensibly used as measures of location and spread respectively.Calculate the mean and the standard deviation of the ages.The mean and the standard deviation of the ages of the people in the queue on Monday evening were 29 and 6.2 respectively. Compare the ages of the people queuing atthe cinema in the afternoon with those in the evening.
16Examination style question a) The mean and the standard deviation are appropriate, as the distribution of ages is roughly symmetrical and there are no outliers.b)The cinemagoers in the evening had a smaller mean age, meaning that they were, on average, younger than those in the afternoon.The standard deviation for the ages in the evening was also smaller, suggesting that the evening audience were closer together in age.
17Combining sets of dataSometimes in examination questions you are asked to pool two sets of data together.Example: Six male and five female students sit an A level examination.The mean marks were 52% and 57% for the males and females respectively. The standard deviations were 14 and 18 respectively.Find the combined mean and the standard deviation for the marks of all 11 students.
18Combining sets of data Let be the marks for the 6 male students. Let be the marks of the 5 female students.To find the overall mean, we first need to find the total marks for all 11 students.ThereforeSo the combined mean is:
19Combining sets of dataTo find the overall standard deviation, we need to find the total of the marks squared for all 11 students.Notice that the formularearranges to giveTherefore,So the combined s.d. is: to 3 s.f.
20VARIANCE - you consider how the values are spread about the mean To calculate VARIANCE, δ2, for a POPULATIONFor a list of data:δ2 = Σ x2 _ μ2nFor grouped data:δ2 = Σ fx2 _ μ2ΣfRemember - μ is the mean of the populationAs this is measured in terms of x2 then the units would be x2 - a bit strange when comparing with original valuesSo to measure in terms of x we often calculate the STANDARD DEVIATION
21STANDARD DEVIATION - the positive square root of the variance Therefore STANDARD DEVIATION, δ, of a POPULATIONFor a list of data:δ = Σ x2 _ μ2nFor grouped data:δ = Σ fx2 _ μ2Σf√√
22δ2 = Σ x2 _ μ2 n This is the whole POPULATION δ2 = 4 6 7 5 9 10 8 For a list of data:δ2 = Σ x2 _ μ2nΣ x2 =Σ x =n =So μ = Σ xnδ2 =
24Quartiles and box plots A set of data can be summarised using 5 key statistics:the median value (denoted Q2) – this is the middle number once the data has been written in order. If there are n numbers in order, the median lies in position ½ (n + 1).the lower quartile (Q1) – this value lies one quarter of the way through the ordered data;the upper quartile (Q3) – this lies three quarters of the way through the distribution.the smallest valueand the largest value.
25Quartiles and box plots These five numbers can be shown on a simple diagram known as a box-and-whisker plot (or box plot):Smallest valueQ1Q2Q3Largest valueNote: The box width is the inter-quartile range.Inter-quartile range = Q3 – Q1The inter-quartile range is a measure of spread.The semi-inter-quartile range = ½ (Q3 – Q1).
26Quartiles and box plots Example: The (ordered) ages of 15 brides marrying at a registry office one month in 1991 were:18, 20, 20, 22, 23, 23, 25, 26, 29, 30, 32, 34, 38, 44, 53The median is the ½(15 + 1) = 8th number. So, Q2 = 26.The lower quartile is the median of the numbers below Q2,So, Q1 = 22The upper quartile is the median of the numbers above Q2,So, Q3 = 34.The smallest and largest numbers are 18 and 53.
27Quartiles and box plots The (ordered) ages of 12 brides marrying at the registry office in the same month in 2005 were:21, 24, 25, 25, 27, 28, 31, 34, 37, 43, 47, 61Q2 is half-way between the 6th and 7th numbers: Q2 = 29.5.Q1 is the median of the smallest 6 numbers: Q1 = 25Q3 is the median of the highest 6 numbers: Q3 = 40.The smallest and highest numbers are 21 and 61.
28Quartiles and box plots A box plot to compare the ages of brides in 1991 and 2005It is important that the two box plots are drawn on the same scale.We can use the box plots to compare the two distributions.The median values show that the brides in 1991 were generally younger than in The inter-quartile range was larger in 2005 meaning that that there was greater variation in the ages of brides in 2005.Note: When asked to compare data, always write your comparisons in the context of the question.
29Cumulative frequency diagrams A cumulative frequency diagram is useful for finding the median and the quartiles from data given in a grouped frequency table.There are some important points to remember:the cumulative frequencies should be plotted above the upper class boundaries of the intervals – don’t use the mid-point.points can be joined by a straight line (for a cumulative frequency polygon) or by a curve (for a cumulative frequency curve).A cumulative frequency polygon
30Cumulative frequency diagrams Example: A survey was carried out into the number of hours a group of employees worked.Hours workedFrequency1 – 9310 – 19520 – 2930 – 393540 – 496550 – 5927The upper class boundary (u.c.b.) of the first interval is actually 9.5 (as it contains all values from 0.5 up to 9.5).The table below shows the cumulative frequencies:u.c.b9.519.529.539.549.559.5c.f.381348113140
31Cumulative frequency diagrams As well as plotting the points given in the previous table, we also plot the point (0.5, 0) – no one worked less than 0.5 hours.We can estimate the median by drawing a line across at one half of the total frequency, i.e. at 70. We see that Q2 ≈ 43.For the lower quartile, a line is drawn at 0.25 × 140 = 35. This gives Q1 ≈ 36.Drawing a line at 0.75 × 140 = 105, we see that Q3 ≈ 48.You don’t need to add 1 before halving the frequency when the data is cumulativeSo the inter-quartile range is 48 – 36 = 12.
32Cumulative frequency diagrams Percentiles and decilesInstead of looking at quartiles we can also split the data up in terms of tenths (deciles) and hundredths (percentiles)We can estimate the 3rd decile by drawing a line across at 3/10 of the total frequency, i.e. at 42. We see that D3 ≈ .For the 7th decile, a line is drawn at 0.7 × 140 = 98. This gives D7 ≈ ..
33Cumulative frequency diagrams Examination style question: The cumulative frequency diagram shows the marks achieved by 220 students in a maths examination.a) Estimate the median and the 95th percentile.b) Where should the pass mark of the examination be set if the college wishes 70% of candidates to pass?
34Cumulative frequency diagrams a) The median will be approximately the 220 ÷ 2 = 110th value. This is about 61%.The 95th percentile lies 95% of the way through the data. A line is drawn across at 0.95 × 220 = 209. This gives a mark of 84%.
35Cumulative frequency diagrams The college wants 70% of 220 = 154 students to pass. Therefore 66 students will get a mark below the pass mark.Drawing a line across at 66 gives a pass mark of about 55%.
36HistogramsA histogram can be used to display grouped continuous data. There are some important points to remember:The area of each bar in a histogram should be in proportion to the frequency.When the class widths are not all equal, proportional areas can be achieved by plotting the frequency density on the vertical axis, whereThe class width of an interval is calculated as the difference between the smallest and largest values that could occur in that interval. Upper class boundary minus lower class boundary
37class widths are not all HistogramsExample: 50 overweight adults tested a new diet. The table shows the amount of weight they lost (in kg) in 6 months.Notice that theclass widths are not allequal – frequencydensities need tobe used.Weight loss (kg)Frequency0 – 4124 – 6136 – 8118 – 10710 – 15515 – 252Class widthFrequency density43.026.55.53.551100.2
38Histogram to show weight loss HistogramsWeight loss (kg)0 – 44 – 66 – 88 – 1010 – 1515 – 25Frequency density3.06.55.53.510.2Histogram to show weight lossWhen you draw a histogram, remember to:plot the frequency densities on the vertical axis;choose sensible scales for your axes;label both your axes;give the histogram a title.
39Histogram to show weight loss HistogramsHistogram to show weight lossWe can use the histogram to estimate, for example, the number of people who lost at least 12kg:There were 2 people who lost between 15 and 25 kg.To estimate how many people lost between 12 and 15 kg, times this new class width by the frequency density for that class: 3 × 1 = 3.That means that about 5 people lost at least 12 kg.
40HistogramsExample: An ornithologist measures the wing spans (to the nearest mm) of 40 adult robins. Her results are shown below.The measurementsare to the nearest millimetre.The first interval containsall wing spans between194.5 and mmThe first interval actually containsWing span (mm)Frequency8205 – 2099210 – 21411215 – 224225 or over3Actual intervalFreq. density194.5 – 204.50.8204.5 – 209.51.8209.5 – 214.52.2214.5 – 224.50.9224.5 – 244.50.15The last interval is open-ended. We assume that its width is twice that of the previous interval.
41Histograms Example (continued) Interval 194.5 – 204.5 204.5 – 209.5 209.5 – 214.5214.5 – 224.5224.5 – 244.5Freq. density0.81.82.20.90.15A histogram showing the wing spans of robinsFreq. densityWing span (mm)