Howdy! I'm Professor Curtis of Aspire Mountain Academy here with more statistics homework help. Today we're going to learn how to perform a sign hypothesis test of median heights. Here's our problem statement: Use a 5% significance level to test the claim that there is a difference between the actual and reported heights in inches for 12 to 16 year old boys. The data is listed in the table below. Let mu1 denote the mean of the first variable and mu2 denote the mean of the second variable.
OK, so here we've got the first part of our problem, and we're asked to find the null and alternative hypotheses. So the null hypothesis will always be a statement of equality. And the alternative hypothesis typically reflects the claim. Here our claim is that there's a difference between actual and reported heights, so that means we're going to have not equal to as our inequality sign. And that combination of equal-not-equal-to is found here. Good job!
Now the second part wants us to find the test statistic. You may be thinking since we have actual data here that we can just dump this into StatCrunch and then, you know, have StatCrunch perform the hypothesis test for us. Unfortunately, the sign hypothesis test feature of StatCrunch works only if you've got less than 25 for a sample size. So we actually have more than that for sample size here because, if you look, we've got one, two, three, four, five, six, seven, eight, nine, ten columns, three rows. 10 times 3 is 30. So StatCrunch will not calculate our test statistic for us. And that's why we can't actually use StatCrunch for this dataset.
We can, however, use Excel to kind of accelerate the “old school” way of doing this. So let's go ahead and just dump this data in Excel, and I actually have that right here. So here we have the data here in Excel. So the first thing I need to do is get my differences so I can count the number of positive signs and negative signs. So I'm just going to take the first value and subtract it from second value, so the first minus the second.
Then I'm going to take this formula, and I'm going to copy it all the way down. I could drag it, but dragging is really useful only if you've got, like, a few cells to drag it to. I've got more than just a few, so I'm going to copy this by pressing Ctrl+C on my keyboard. And then using my arrow keys, I'm going to go down to the bottom of the list by pressing Ctrl while I hit the down arrow. That takes me to the bottom of the list. So I want these copied cells to end here.
So now I'm going to put my --- see I've got my, I've got that cell selected there --- and now I'm going to go and press Ctrl+Shift on my keyboard while I press the up arrow. It takes me to the top of the list. Now these cells that are shaded are going to be the ones where I want to copy my formula. So now I press Ctrl+V to copy and, look, it's all there for me. When I press Ctrl+Down it takes me --- wow, it's the bottom of my list. And so now here, right down here, I'm actually doing my count. So let's count positives first, and then let's do negatives.
So here I've got the counting of the number of the positives, and I'm going to use the COUNTIF function to do that. COUNTIF says we're going to select where we want to do our counting, but we only want the computer to include a cell in the count if it meets certain criteria. And here we're going to have the criteria be that the number is positive. So I open my parentheses, and now I need to select my range. And I do that by going up to this next cell up here and then Ctrl+Shift+ [on my keyboard] Up arrow takes me to the top of the list. There's my range. I put in a comma so I can put in the next element of the function. Now it's asking for the criteria. Typically we put the criteria in quotation marks. And we want these to be positive numbers; that's going to be greater than zero. And I close my parentheses, and now there's my formula. I hit Enter, and it automatically counted all the positive numbers for me.
I'm going to do the same thing with the negative numbers so we can get a quick count of them. And you know, if it we're just a handful of numbers, I wouldn't mind just counting them myself, but I got more than just a little handful here.
Alright, so we've got 18 and 10; that adds to 28. We've got a couple of zeros in the list. Here's one here. And if we scroll up a little bit, we can see the second one here. So zeros, of course, are not included in our counts because we don't really want those included. So now I've got 18 positive and 10 negative. Now I got my summary stats that I can use to actually calculate my test statistic with.
And to do that, we're going to go back to our handy dandy z-score formula. So here we're going to see that X is the less of those two numbers. So that's going to be 10. And N is going to be the sum of those two numbers, which is 28. So now we substitute those into our formula and --- well, that should actually be a 28 there. Well, that's a typo. And then, yeah, so we got that number fixed right here. And then we just simplify that expression. Punch it out on the calculator, and here comes our test statistic: -1.32. Nice work!
Now we're asked to find the P-value. And here StatCrunch actually is rather helpful for finding the P-value. So we're going to go back to the --- I mean, because alternatively, we could use the z-score tables, but I'm lazy. I like the 21st century. I want to use technology. And we're going to have to work a little bit anyway to get our P-value because we've got a two-tailed test.
So here in StatCrunch, I want to go to Stat --> Calculators --> Normal. Here in my calculator I want to select the Between option because, as you see here, we have a two tail test here. I'm going to put in my test statistics. So on the negative side -1.32, and I want to put in all those decimal places that I had before. So let me move this over so I can stick all that in and get 1.322875. And I put the positive version of my test statistic here. And now StatCrunch has calculated the area in between the tails. The P-value is the area in the tails. So I want to take this number, and in my calculator I'm going to subtract that from 1. And there's my P-value. I’m asked to round to four decimal places. So let's see, that brings me out to there. Excellent!
And now the last part asks, "Is there sufficient evidence to support H1?" Well, supporting H1, or the alternative hypothesis, is the same thing as rejecting the null hypothesis. Can we reject the null hypothesis? Well, we've got a P-value of almost 19%. It's well above our significance level of 5%, so we're outside the region of rejection. We fail to reject the null hypothesis, and therefore we fail to support the alternative hypothesis. Good job!
And that's how we do it at Aspire Mountain Academy. Be sure to leave your comments below and let us know how good a job we did or how we can improve. And if your stats teacher is boring or just doesn't want to help you learn stats, go to aspiremountainacademy.com, where you can learn more about accessing our lecture videos or provide feedback on what you'd like to see. Thanks for watching! We'll see you in the next video.
Frustrated with a particular MyStatLab/MyMathLab homework problem? No worries! I'm Professor Curtis, and I'm here to help.