The following is a solution in over 14 goodness of fit test where we look at the distribution of customer ages in a snoop report and see if it gives it agrees with the report from the sample. So the observed data values here uh were given to you in the book. So 88 1 35 50 to 40 76 1 28. I went ahead and just copy those down. And then for the expected, you gotta take the percent Times the sample size to get the actual expected value. So 12% times 519, for example, is 62.28. So I did that for all six categories there for the different age ranges. So now we're ready to go ahead and To answer these questions. So what's the significance level that they give? They give you that in the problem? It's a 1% significance level. So alpha's .01. And then we also need to write down what are null and alternative hypotheses are now typically for goodness of fit, test the Noles that these two distributions are the same. And then the alternative is that they're not the same. So in this particular case, bringing it back to this example, we're going to say the distribution of customer ages, uh and the snoop report, I'm not sure what a stupid port is, agrees with the sample report. Right? And then the alternative is that they don't agree. So, the distribution of customer ages and the stoop report does not agree with those of the sample report. So now we need to find the chi square value, but before we do that, we need to make sure that the expected values are greater than five and they are. So the expected values already found them, and you just take the percent times the sample size and they're all greater than five. So that's one of those conditions for inference they need to be at least five and they are so we can use the chi square distribution because of that with five degrees of freedom. Now why is it that five degrees of freedom? Well because there are six categories 1234566 categories minus one is five. That's always gonna give you the degrees of freedom. So now we can find basically everything else with software. So I'm gonna use the T. IT. for like using the T. 84 for smaller data sets. Um But you can use Excel or are or SAs or mini tab whichever you prefer. Or you can certainly use the formula. It might take you a little longer but you can use the formula. So I went ahead and typed these in already but I put an L1 I put the observed data values so you can see him there and then an L. Two. I put the expected data values you can see him there. So what I like to do sometimes is look at the difference here and these look to be kind of far apart. At least some of them do. So I don't know. I think it's been close but I don't think this is going to be a very good fit. Well let's see. So if we're gonna stat and then tests and it's one of the last ones I went up first. It's the D option if you're using A T. I. T. For. And it's the chi square geo F. Test that stands for goodness of fit test. L one is your observed, assuming you put it in. L one. L two is the expected degrees of freedom. Was five. Remember? And then we calculate and that's gonna give us the two values that we need to. The chi square value. Is this first number right here? 15.651 15 651 And then the P. Value, I don't know if you saw it there but we'll go in round. It's about .008 0.8 So just what I thought it's less than alpha. So anytime the P values less than alpha we this is the beauty of the P value. Matthew explicitly compared the P value with the alpha value. And if it's less than alpha then you always reject the null hypothesis. So we're going to reject h. Not so we're rejecting the claim that the distribution of customer ages and the snoop report agrees with the sample report. So that's how we conclude that will go and say there is. Oops. Well, I didn't mean to do that. Yeah, I can just type it in I guess. Mm. Sorry. Okay. I'll just I'll just actually write this out so there is okay, sufficient evidence to suggest the distribution of customer ages does not agree with that of the sample report. Okay. So these two distributions are not the same.