Survey
* Your assessment is very important for improving the workof artificial intelligence, which forms the content of this project
* Your assessment is very important for improving the workof artificial intelligence, which forms the content of this project
Working with grouped data It is sometimes easiest to work with data where you have frequencies of values instead of a long list of single values. For example, instead of using a list such as this 3,5,6,4,3,5,4,4,7,8,3,5,6,4,5,5,6 your data is in a table like this VALUE 3 4 5 6 7 8 FREQUENCY 3 4 5 3 1 1 Product 9 16 25 18 7 8 For the list, you need to add all together, 3+5+6+…+5+6 = 83 For the table, you add the products, 3*3 + 4*4 + … + 8*1 = 83 MEAN The mean of grouped data, then, is the sum of the products divided by N. To do this in Excel or a similar spreadsheet, let us say that the values are in column A (rows 1 to 6) and the frequencies column B. We will put the mean (the average) in cell C1. =SUMPRODUCT(A1:A6,B1:B6)/SUM(B1:B6) For our example, this = 4.9 VARIANCE of a sample There is a formula for calculating the variance of grouped data, as shown below in Figure 1. In excel, we will use the first version of the equation. This sums the products of (the frequency of each value) x ((the difference of each value from the mean)squared), divided by N-1 (since we are interested in the variance of a sample, not the variance of a population): =SUMPRODUCT(B1:B6,(A1:A6-C1)^2)/(SUM(B1:B6)-1) Let us put the variance (1.99) in C2. Standard Deviation for a sample The S.D. is just the square root of the variance, which is excel is =SQRT(C2) =1.41 Fig. 1. Calculating the variance for grouped data (source: http://www.lboro.ac.uk/media/wwwlboroacuk/content/mlsc/downloads/var_ stand_deviat_group.pdf ).