Normality Check on TI-83/84
Copyright © 2012–2014 by Stan Brown, Oak Road Systems
Copyright © 2012–2014 by Stan Brown, Oak Road Systems
But just looking at a plot, you may not be sure whether it’s “close enough” to a straight line, especially with smaller data sets. Most of the time, you need to make some fairly gnarly computations to answer that question.
This note shows you how to make the plot and do the computations for an example, and then in an appendix it gives the theory behind all of this.
Alternative: Making the plot is easy enough, but the calculations require a lot of keyboarding. MATH200A Program part 4 does the whole thing automatically for you, so use it if you possibly can.
Consider these vehicle weights (in pounds):
Construct a plot to decide whether these vehicle weights seem to be normally distributed.
|Enter the data points.||
Cursor onto the label
Enter the data values. (The order doesn’t matter.)
In this step, you disable any other plots and graphs that could overlay your box-whisker plot.
|Look at the plots across the top, and look at the column of = signs. If any are enabled (highlighted), disable them.||
Use the arrow keys to get to any highlight, and press
Caution! There are ten equations. Use [
|Clear the grid and enable coordinate display for later use in tracing.||
If GridOn is highlighted, press [
If CoordOff is highlighted, use the [
|Select Plot1.||Press [|
|Select the modified box-whisker plot.||Press [|
|Select list 1, data axis X, and squares for plotting.||
If this plot is close to a straight line, then the data set is close to a normal distribution. But how close is close enough? If you’re very lucky, the plot will be an obvious straight line, or it will be very far from a straight line. Then you can declare the data normal or not normal, and stop. But usually the plot is iffy, and you could go either way just from looking at it.
What about the plot for our example? There are certainly some bumps, but is the plot too far from a straight line? It’s hard to say. This is one of those iffy cases that you usually get.
The solution is to compute a correlation coefficient and a critical value, and compare them. The correlation coefficient is the same one you already know from an earlier chapter. The critical value is not the decision point from that chapter, for reasons explained in the appendix.
The x’s in the plot are your data values. You have an xy scatter plot, so it must have an r. The problem is that the calculator created the y’s behind the scenes, using the rules in the appendix, and it doesn’t give you any easy way to get at the y’s or the r. So you actually have to duplicate the calculator’s work.
(Again, MATH200A part 4 does all these calculations for you, so it’s really worth your while to download it. But if you can’t do that, keep reading and follow along.)
|Sort the data points.|| Press [|
The next calculations could all be combined into one very long command storing into L2, but it would be really easy to make mistakes in such a long formula. Instead, I’ve broken the calculations into chunks.
|Get the numbers 1, 2, 3, ... into L2.||
Press [x,T,θ,n] [
Finish with [
|Get the normal probabilities into L3. (The normal probabilities are the probabilities of getting each data point or a lower one by random selection, if the data points are normally distributed. The appendix gives the formula (i−0.375)/(n+0.25), where i is the numbers 1, 2, 3, and n is the sample size.||
|Find z scores that correspond to those probabilities. These are the z-scores that your data would have if they are normally distributed, and they are the y’s that your calculator used for the normal probability plot above.||
Enter the number of data points, then finish with [
|Now at long last you’re ready to compute r. This is the correlation coefficient of the points in the normal probability plot, and it tells you how close those points lie to a straight line.||
(If r doesn’t appear and you get only a and b, run the DiagnosticOn command as explained in the Setup step of Scatter Plot, Correlation, and Regression on TI-83/84.)
The correlation coefficient of .9599 (about .96) seems pretty good, but is it good enough? To answer this question, you have to compare it to a critical value. If r > crit, the data set is normally distributed. If r < crit, the data set is not normally distributed.
|The formula for crit is 1.0063−.6118/n+1.3505/n²−.1288/√n, where n is the sample size.||Enter that formula in your calculator, but with your actual number of data points in place of n. This data set has 10 points.|
Whew! r = 0.9599 and crit = 0.9179. r > crit, and therefore you can say that the data set is close enough to a normal distribution.
The basic idea isn’t too bad. You make an xy scatter plot where the x’s are the data points, sorted in ascending order, and the y’s are the expected z scores for a normal distribution. (I’m going to abbreviate “normally distributed” or “normal distribution” as ND to save wear and tear on my keyboard and your eyes.)
Why would you expect that to be a straight line? Recall the formula for a z score: z = (x−x̅)/s. Breaking the one fraction into two, you have z = x/s−x̅/s. That’s just a linear equation, with slope 1/s and intercept x̅/s. So if you make an xz plot of any data set, plotting each data point’s z score against the actual data value, you should have a straight line. Further, if the data points are ND, then their expected z scores will match their actual z scores, and therefore an xy scatter plot of expected z scores against actual data values will also be a straight line.
Now, in real life no data set is ever exactly a ND, so you won’t ever expect to see a straight line. Instead, you say that the closer the points are to a straight line, the closer the data set is to normal. If the data points are too far from a straight line — if their correlation coefficient r is lower than some critical value — then you reject the idea that the data set is ND.
Okay, so you have to plot the data points against what their z-scores should be if this is a ND, and specifically for a sample of n points from a ND, where n is your sample size. This must be built up in a sequence of steps:
The closer the points are to a straight line, the closer the data set is to fitting a normal model. In other words, a larger r indicates a ND, and a smaller r indicates a non-ND. You can draw one of two conclusions:
(If you haven’t studied hypothesis testing yet, another way to say it is that you’re pretty sure the data set doesn’t fit the normal model because there’s less than a 5% probability that it does.)
This doesn’t mean you are certain it does, merely that you can’t rule it out. Technically you don’t know either way, but practically it doesn’t matter. Remember (or you will learn later) that inferential statistics procedures like t tests are robust, meaning that they still work even if the data are moderately non-normal. But if your data were extremely non-normal, r would be less than the critical value. When r is greater than the critical value, you don’t know whether the data set comes from normal data or moderately non-normal data, but either way your inferential statistics procedures are okay.
So the bottom line is, if r > CRIT, treat the data as normal, and if r < CRIT, don’t.