Facoltà di Scienze della Formazione, Scienze Politiche e Sociali Statistics for Social Research Lesson 2: Descriptive Statistics Prof.ssa Monica Palma a.a. 2016-2017
DESCRIPTIVE STATISTICS How do we describe a human being? With measures such as height, weight, color of eyes, color of hair, complexion, and the like. Similarly, a group of data is described with certain measures.
DESCRIPTIVE STATISTICS Descriptive Statistics describes a data set A data set is described with two measures: measures of location measures of variability
PARAMETERS AND SAMPLE STATISTICS If the measures are computed for data from a sample, they are called sample statistics. If the measures are computed for data from a population, they are called population parameters. A sample statistic is referred to as the point estimator of the corresponding population parameter.
MEASURES OF LOCATION Mean Median Mode Percentiles Quartiles
MEAN The mean of a data set is the average of all the data values (data from a sample or from a population). The sample mean x is the point estimator of the population mean µ.
SAMPLE MEAN ( ) x n å = i= 1 n x i Sum of the values of the n observations Number of observations in the sample
POPULATION MEAN (µ) N å µ = i= 1 N x i Sum of the values of the N observations Number of observations in the population
SAMPLE MEAN Example Ministerial subsidy for families with disabled children Seventy families with disabled children were randomly sampled in a small town. The monthly ministerial subsidies (expressed in euros) for these families are listed on the next slide.
SAMPLE MEAN Example Ministerial subsidy for families with disabled children 445 615 430 590 435 600 460 600 440 615 440 440 440 525 425 445 575 445 450 450 465 450 525 450 450 460 435 460 465 480 450 470 490 472 475 475 500 480 570 465 600 485 580 470 490 500 549 500 500 480 570 515 450 445 525 535 475 550 480 510 510 575 490 435 600 435 445 435 430 440
SAMPLE MEAN x = n å 34.356 70 i i= 1 = = n x 490.80 445 615 430 590 435 600 460 600 440 615 440 440 440 525 425 445 575 445 450 450 465 450 525 450 450 460 435 460 465 480 450 470 490 472 475 475 500 480 570 465 600 485 580 470 490 500 549 500 500 480 570 515 450 445 525 535 475 550 480 510 510 575 490 435 600 435 445 435 430 440
MEDIAN The median of a data set is the value in the middle when the data items are arranged in ascending order. Whenever a data set has extreme values, the median is the preferred measure of central location. On the other hand, extreme values can affect (i.e. inflate or deflate) the mean.
MEDIAN For an odd number of observations: 26 18 27 12 14 27 19 7 observations 12 14 18 19 26 27 27 in ascending order the median is the middle value. Median = 19
MEDIAN For an even number of observations: 26 18 27 12 14 27 30 19 8 observations 12 14 18 19 26 27 27 30 in ascending order the median is the average of the middle two values. Median = (19 + 26)/2 = 22.5
MEDIAN Example Ministerial subsidy for families with disabled children 425 430 430 435 435 435 435 435 440 440 440 440 440 445 445 445 445 445 450 450 450 450 450 450 450 460 460 460 465 465 465 470 470 472 475 475 475 480 480 480 480 485 490 490 490 500 500 500 500 510 510 515 525 525 525 535 549 550 570 570 575 575 580 590 600 600 600 600 615 615
MEDIAN Averaging the 35th and 36th data values: Median = (475 + 475)/2 = 475 Note: Data is in ascending order 425 430 430 435 435 435 435 435 440 440 440 440 440 445 445 445 445 445 450 450 450 450 450 450 450 460 460 460 465 465 465 470 470 472 475 475 475 480 480 480 480 485 490 490 490 500 500 500 500 510 510 515 525 525 525 535 549 550 570 570 575 575 580 590 600 600 600 600 615 615
MODE The mode of a data set is the value that occurs with greatest frequency. The greatest frequency can occur at two or more different values. If the data have exactly two modes, the data are bimodal. If the data have more than two modes, the data are multimodal.
MODE Example Ministerial subsidy for families with disabled children 425 430 430 435 435 435 435 435 440 440 440 440 440 445 445 445 445 445 450 450 450 450 450 450 450 460 460 460 465 465 465 470 470 472 475 475 475 480 480 480 480 485 490 490 490 500 500 500 500 510 510 515 525 525 525 535 549 550 570 570 575 575 580 590 600 600 600 600 615 615
MODE 450 occurred most frequently (7 times) Mode = 450 Note: Data is in ascending order 425 430 430 435 435 435 435 435 440 440 440 440 440 445 445 445 445 445 450 450 450 450 450 450 450 460 460 460 465 465 465 470 470 472 475 475 475 480 480 480 480 485 490 490 490 500 500 500 500 510 510 515 525 525 525 535 549 550 570 570 575 575 580 590 600 600 600 600 615 615
PERCENTILES Percentiles divide a data set into 100 equal parts. There are 99 percentiles. Example Admission test scores for colleges are reported in percentiles.
PERCENTILES Percentiles divide a data set into 100 equal parts. There are 99 percentiles. The p-th percentile of a data set is a value such that: at least p percent of the items take on this value or less and at least (100 - p) percent of the items take on this value or more.
PERCENTILES Arrange the data in ascending order. Compute index i, the position of the p-th percentile: i = (p/100)n If i is not an integer, round up. The p-th percentile is the value in the i-th position. If i is an integer, the p-th percentile is the average of the values in positions i and i +1.
80 TH PERCENTILES Example Ministerial subsidy for families with disabled children 425 430 430 435 435 435 435 435 440 440 440 440 440 445 445 445 445 445 450 450 450 450 450 450 450 460 460 460 465 465 465 470 470 472 475 475 475 480 480 480 480 485 490 490 490 500 500 500 500 510 510 515 525 525 525 535 549 550 570 570 575 575 580 590 600 600 600 600 615 615
80 TH PERCENTILES i = (p/100)n = (80/100)70 = 56 Averaging the 56 th and 57 th data values: 80 th Percentile = (535 + 549)/2 = 542 Note: Data is in ascending order 425 430 430 435 435 435 435 435 440 440 440 440 440 445 445 445 445 445 450 450 450 450 450 450 450 460 460 460 465 465 465 470 470 472 475 475 475 480 480 480 480 485 490 490 490 500 500 500 500 510 510 515 525 525 525 535 549 550 570 570 575 575 580 590 600 600 600 600 615 615
80 TH PERCENTILES At least 80% of the items take on a value of 542 or less. At least 20% of the items take on a value of 542 or more. 56/70 = 0.8 or 80% 14/70 = 0.2 or 20% 425 430 430 435 435 435 435 435 440 440 440 440 440 445 445 445 445 445 450 450 450 450 450 450 450 460 460 460 465 465 465 470 470 472 475 475 475 480 480 480 480 485 490 490 490 500 500 500 500 510 510 515 525 525 525 535 549 550 570 570 575 575 580 590 600 600 600 600 615 615
QUARTILES Quartiles divide a data set into four equal parts. There are three quartiles: Q 1, Q 2 and Q 3. The first quartile (Q 1 ) represents the 25-th percentile. The second quartile (Q 2 ) represents the 50-th percentile. The third quartile (Q 3 ) represents the 75-th percentile. ---------------Q 1 --------------Q 2 ---------------Q 3 --------------
QUARTILES Example Ministerial subsidy for families with disabled children 425 430 430 435 435 435 435 435 440 440 440 440 440 445 445 445 445 445 450 450 450 450 450 450 450 460 460 460 465 465 465 470 470 472 475 475 475 480 480 480 480 485 490 490 490 500 500 500 500 510 510 515 525 525 525 535 549 550 570 570 575 575 580 590 600 600 600 600 615 615
THE THIRD QUARTILE (Q 3 ) Third quartile = 75-th percentile i = (p/100)n = (75/100)70 = 52.5 = 53 Third quartile (Q 3 ) = 525 Note: Data is in ascending order 425 430 430 435 435 435 435 435 440 440 440 440 440 445 445 445 445 445 450 450 450 450 450 450 450 460 460 460 465 465 465 470 470 472 475 475 475 480 480 480 480 485 490 490 490 500 500 500 500 510 510 515 525 525 525 535 549 550 570 570 575 575 580 590 600 600 600 600 615 615
MEASURES OF VARIABILITY Measures of location alone do not fully describe a data set. We need an additional measure. It is often desirable to consider measures of variability (dispersion), as well as measures of location.
MEAN AND VARIANCE Example Look at the following two data sets: 20 40 50 50 60 75 80 85 90 100 50 60 60 60 65 65 70 70 70 80 The mean is the same in both data sets (65). However, there is a difference between the data sets. What s the difference? In the first data set, data values vary widely. The data values in the second set are closer together. The mean alone does not fully describe a data set.
MEASURES OF VARIABILITY Range Interquartile Range Variance Standard Deviation Coefficient of Variation
RANGE The Range of a data set is the difference between the largest and smallest data values. It is the simplest measure of variability. It is very sensitive to the smallest and largest data values.
RANGE Example Ministerial subsidy for families with disabled children 425 430 430 435 435 435 435 435 440 440 440 440 440 445 445 445 445 445 450 450 450 450 450 450 450 460 460 460 465 465 465 470 470 472 475 475 475 480 480 480 480 485 490 490 490 500 500 500 500 510 510 515 525 525 525 535 549 550 570 570 575 575 580 590 600 600 600 600 615 615
RANGE Range = largest value - smallest value Range = 615-425 = 190 Note: Data is in ascending order 425 430 430 435 435 435 435 435 440 440 440 440 440 445 445 445 445 445 450 450 450 450 450 450 450 460 460 460 465 465 465 470 470 472 475 475 475 480 480 480 480 485 490 490 490 500 500 500 500 510 510 515 525 525 525 535 549 550 570 570 575 575 580 590 600 600 600 600 615 615
INTERQUARTILE RANGE The Interquartile Range of a data set is the difference between the third quartile and the first quartile. It is the range for the middle 50% of the data. It overcomes the sensitivity to extreme data values.
INTERQUARTILE RANGE Example Ministerial subsidy for families with disabled children 425 430 430 435 435 435 435 435 440 440 440 440 440 445 445 445 445 445 450 450 450 450 450 450 450 460 460 460 465 465 465 470 470 472 475 475 475 480 480 480 480 485 490 490 490 500 500 500 500 510 510 515 525 525 525 535 549 550 570 570 575 575 580 590 600 600 600 600 615 615
INTERQUARTILE RANGE 3 rd Quartile (Q 3 ) = 525 1 st Quartile (Q 1 ) = 445 Interquartile Range = Q 3 - Q 1 = 525-445 = 80 Note: Data is in ascending order 425 430 430 435 435 435 435 435 440 440 440 440 440 445 445 445 445 445 450 450 450 450 450 450 450 460 460 460 465 465 465 470 470 472 475 475 475 480 480 480 480 485 490 490 490 500 500 500 500 510 510 515 525 525 525 535 549 550 570 570 575 575 580 590 600 600 600 600 615 615
VARIANCE The variance is a measure of variability that is based to all the data. It is based on the difference between the value of each observation (x i ) and the mean ( x for a sample, µ for a population).
VARIANCE The Variance is the average of the squared differences between each data value and the mean. The Variance is computed as follows: s n å ( x i -x) = i = n-1 2 1 2 2 s N å i= = 1 ( x - µ) i N 2 for a sample for a population
STANDARD DEVIATION The standard deviation of a data set is the positive square root of the variance. It is measured in the same units as the data, making it more easily interpreted than the variance.
STANDARD DEVIATION The standard deviation is computed as follows: 2 s = s s = s 2 for a sample for a population
COEFFICIENT OF VARIATION The Coefficient of Variation indicates how large the standard deviation is in relation to the mean. The Coefficient of Variation is computed as follows: æ ç è s x ö 100 % ø æs çç è µ 100 ø ö % for a sample for a population
VARIANCE, STANDARD DEVIATION, AND COEFFICIENT OF VARIATION Example Ministerial subsidy for families with disabled children 425 430 430 435 435 435 435 435 440 440 440 440 440 445 445 445 445 445 450 450 450 450 450 450 450 460 460 460 465 465 465 470 470 472 475 475 475 480 480 480 480 485 490 490 490 500 500 500 500 510 510 515 525 525 525 535 549 550 570 570 575 575 580 590 600 600 600 600 615 615
VARIANCE, STANDARD DEVIATION, AND COEFFICIENT OF VARIATION Variance: s n å ( x i -x) = i = n-1 2 1 Standard Deviation: s 2 = s 2 = Coefficient of Variation: = 54.74 2,996.16 the standard deviation is about 11% of the mean æ ç è s x ö æ 54.74 ö 100 % = ç 100 % = 11.15% ø è 490.80 ø
SAMPLE PROBLEM Problem From a survey, the car rental rates measured in a sample of Southern Italy cities are 43 35 34 58 30 30 36 Compute: a) mean, b) variance and c) standard deviation. a) Mean car rental rate in Southern Italy cities is: (43+35+34+58+30+30+36)/7 = 38 b) Variance is: [(43-38) 2 + (35-38) 2 + (34-38) 2 + (58-38) 2 + (30-38) 2 + (30-38) 2 + (36-38) 2 ] / (7-1) = 582/6 = 97 c) Standard Deviation is: 97 = 9.85 Interpretation: Car rental rates deviate, on the average, from the mean by 9.85
MORE ON STANDARD DEVIATION What is standard deviation? Standard deviation is a numeric measure of the overall variation of a data set from its mean. If the data values of a data set are closer together, its standard deviation is small while it is large for data values that are widely apart. Standard deviation also depends on the numeric size of data values. If we are dealing with numerically large data values (such as home prices, salaries, and the like), the standard deviation will be a large number. On the other hand, the standard deviation will be small for small data values (such as number of courses enrolled, number of credit cards, etc.).
MORE ON STANDARD DEVIATION Let s take two examples Example 1: #Student Grants Example 2: Home Prices Students # Grants # 1 4 2 0 3 2 4 3 Home # Price 1 400,000 2 370,000 3 350,000 4 330,000 5 1 5 300,000 x = 2 x =350,000 s =1.58 s =1.58 By looking at these numbers, we cannot conclude that home prices have a larger variation. Calculate the Coefficient of Variation and see what the numbers look like.
MORE ON STANDARD DEVIATION Calculation of Coefficient of Variation Example 1: #Student Grants Students # Grants # 1 4 2 0 3 2 4 3 5 1 Coefficient of Variation = (s/ )*100 = 79.06% x Example 2: Home Prices Home # Price 1 400,000 2 370,000 3 350,000 4 330,000 5 300,000 Coefficient of Variation = (s/ )*100 = 10.88% x The number of student grants shows a larger variation compared to home price.
END OF LESSON 2