Don't crash on Games-Howell test when there are small numbers of cases per category.
[pspp-builds.git] / tests / language / stats / oneway.at
index ce121beb977dac2bda33886450fd4689d24e09e9..dfb43bbe909bafafbae78cb46f7a31eea9dc3029 100644 (file)
@@ -900,4 +900,75 @@ temperature,Assume equal variances,1,-.98,2.74,.36,6,.73
 ,,3,-8.83,18.66,-.47,4.19,1.34
 ])
 
-AT_CLEANUP
\ No newline at end of file
+AT_CLEANUP
+
+
+AT_SETUP([ONEWAY crash on single category independent variable])
+AT_DATA([crash.sps],[
+input program.
+loop #i = 1 to 10.
+compute test = #i.
+end case.
+end loop.
+end file.
+end input program.
+
+compute x = 1.
+
+oneway test by x.
+])
+
+AT_CHECK([pspp -O format=csv crash.sps], [0], [ignore])
+
+AT_CLEANUP
+
+
+
+AT_SETUP([ONEWAY crash on missing dependent variable])
+AT_DATA([crash2.sps],[dnl
+data list notable list /dv1 * dv2  *  y * .
+begin data.
+2  .  2     
+1  .  2 
+1  .  1    
+2  .  4    
+3  .  4
+4  .  4    
+5  .  4    
+end data.
+
+ONEWAY 
+       /VARIABLES= dv1 dv2  BY y
+       /STATISTICS = DESCRIPTIVES
+       /POSTHOC = BONFERRONI LSD SCHEFFE SIDAK TUKEY
+       /MISSING = ANALYSIS      
+       .
+])
+
+AT_CHECK([pspp -O format=csv crash2.sps], [0], [ignore])
+
+AT_CLEANUP
+
+
+
+
+AT_SETUP([ONEWAY Games-Howell test with few cases])
+AT_DATA([crash3.sps],[dnl
+data list notable list /dv * y * .
+begin data.
+2 2
+1 2
+1 1
+2 4
+3 4
+end data.
+
+ONEWAY
+ /VARIABLES= dv BY y
+ /POSTHOC = GH
+ . 
+])
+
+AT_CHECK([pspp -O format=csv crash3.sps], [0], [ignore])
+
+AT_CLEANUP