The Math Forum

Ask Dr. Math - Questions and Answers from our Archives
Associated Topics || Dr. Math Home || Search Dr. Math

Statistics - t-test

Date: 01/15/2002 at 17:52:25
From: Pierre Flute
Subject: Statistics - t test

I am comparing scores of basketball games to see if playing at home 
is an advantage over playing away. I looked in a math book and it said 
to use a t-test. I have 253 games on an Excel spreadsheet. Excel did 
the t-test but I don't know if I am right in doing the t-test. Are 
there any other tests I should do instead or in addition? So far, I 
also have the mean of home scores, mean of away scores, difference 
between the means, total games, total home wins, total away wins, and 
percentage of home and away wins.

Date: 01/17/2002 at 07:33:57
From: Doctor Mitteldorf
Subject: Re: Statistics - t test

Dear Pierre,

The t-test is fine, and it may be all you need for this project. If 
you'd like to write back with the numbers and show exactly what you 
did, I'd be glad to check it and help you interpret your results.

Here's an idea for a project that you might like to take on. It's an 
example of a "Monte Carlo Simulation." The beauty of this approach is 
that it makes no assumptions about your data, so it produces the most 
unbiased answer available. It avoids pre-conceived ideas about what 
standard tests might be relevant.

Here's what to do. Take all 506 team scores, home and away, and make 
a single list of them.  Shuffle the list to put them in a random 
order. Then pretend that the first two scores made a "game" and mark 
"H" for home if the first team won, and "A" for away if the second 
team won. How many more games did the home team win than the away 
team? If the difference was greater than you observed in real life, 
call that an "exceedance." 

Now repeat this whole process a million times. You'll want to do this 
with a computer program, not by hand. (You can do it on a spreadsheet 
if you want, but you can only fit a few thousand trials on common 
spreadsheet programs. A language like BASIC or LOGO or PASCAL will be 
faster and let you use bigger numbers.) You'll do a million shuffles, 
and a million sets of games, each set having 253 games in it.

Of those million trials, how many had more exceedances than you had in 
real life? That's an important number, because it gives you an idea 
how often you might expect the difference you got by chance. Say there 
were 100,000 exceedances out of a million. That would indicate there 
was a 10% chance that your results could have been just a chance 
occurrence. Not very impressive. But if you only had 10,000 
exceedances, that would be the basis for saying that maybe you were 
looking at somethig real.

You might also do the same kind of simulation, but count the point 
differences instead of the number of wins. An "exceedance" would then 
be defined as a trial in which the point difference was greater than 
what occurred in real life.

- Doctor Mitteldorf, The Math Forum   
Associated Topics:
College Statistics
High School Statistics

Search the Dr. Math Library:

Find items containing (put spaces between keywords):
Click only once for faster results:

[ Choose "whole words" when searching for a word like age.]

all keywords, in any order at least one, that exact phrase
parts of words whole words

Submit your own question to Dr. Math

[Privacy Policy] [Terms of Use]

Math Forum Home || Math Library || Quick Reference || Math Forum Search

Ask Dr. MathTM
© 1994- The Math Forum at NCTM. All rights reserved.