|
|
CHI SQUARE TWO SAMPLEName:
Dataplot supports the chi-square two sample test for either binned or unbinned data. For unbinned data, Dataplot automatically generates binned data using the same rule as for histograms. That is, the class width is 0.3*s where s is the sample standard deviation. The upper and lower limits are the mean plus or minus 6 times the sample standard deviation (any zero frequency bins in the tails are omitted). Note that the binning computations are performed with the combined data set. As with the HISTOGRAM command, you can override these defaults using the CLASS WIDTH, CLASS UPPER, and CLASS LOWER commands. The quantile-quantile plot, bihistogram, and Tukey mean-difference plot are graphical alternatives.
where <y1> is the first response variable; <y2> is the second response variable; and where the <SUBSET/EXCEPT/FOR qualification> is optional. This syntax is used for unbinned data.
where <y1> is the first response variable; <y2> is the second response variable; <x> is a variable containing the mid-points of the bins; and where the <SUBSET/EXCEPT/FOR qualification> is optional.
This syntax is used for binned data. The
CHI-SQUARE TWO SAMPLE TEST Y1 Y2 X CHI-SQUARE TWO SAMPLE TEST Y1 Y2 X SUBSET Y2 > 0
STATNU - degrees of freedom for the chi-square two sample test STATCDF - cdf value for the chi-square two sample test statistic CUTUPP90 - 90% critical value (alpha = 0.10) for the chi-square two sample test statistic CUTUPP95 - 95% critical value (alpha = 0.05) for the chi-square two sample test statistic CUTUPP99 - 99% critical value (alpha = 0.01) for the chi-square two sample test statistic
CHISQUARE TWO SAMPLE TEST CHI SQUARE 2 SAMPLE TEST CHISQUARE 2 SAMPLE TEST TWO SAMPLE CHI SQUARE TEST TWO SAMPLE CHISQUARE TEST 2 SAMPLE CHI SQUARE TEST 2 SAMPLE CHISQUARE TEST The word TEST in the above commands is optional.
READ AUTO83B.DAT Y1 Y2 . DELETE Y2 SUBSET Y2 < 0 CHI SQUARE TWO SAMPLE TEST Y1 Y2 The following output is generated.
****************************************
** CHI-SQUARE TWO SAMPLE TEST Y1 Y2 **
****************************************
CHI-SQUARED TWO SAMPLE TEST
NULL HYPOTHESIS H0: TWO SAMPLES COME FROM THE SAME (UNSPECIFIED)
DISTRIBUTION
ALTERNATE HYPOTHESIS HA: TWO SAMPLES COME FROM DIFFERENT DISTRIBUTIONS
SAMPLE:
NUMBER OF OBSERVATIONS FOR SAMPLE 1 = 249
NUMBER OF OBSERVATIONS FOR SAMPLE 2 = 79
NUMBER OF NON-EMPTY CELLS = 17
CLASS WIDTH FOR BINS = 0.1832313E+01
CLASS LOWER FOR BINS = -0.1834362E+02
CLASS UPPER FOR BINS = 0.5863277E+02
TEST:
CHI-SQUARED TEST STATISTIC = 35.33751
DEGREES OF FREEDOM = 17
CHI-SQUARED CDF VALUE = 0.994384
ALPHA LEVEL CUTOFF CONCLUSION
10% 24.76903 REJECT H0
5% 27.58711 REJECT H0
1% 33.40867 REJECT H0
Date created: 6/5/2001 |