MEANS: Added further tests for missing value behaviour
[pspp-builds.git] / tests / language / stats / means.at
index e4d1f5a2f4e682685b7b6db0bec68fe710723936..5bef5e911cea5a65ff27c8e70f5c0493f9e17dee 100644 (file)
@@ -413,3 +413,82 @@ AT_CLEANUP
 
 
 
+
+
+AT_SETUP([MEANS user missing values])
+
+AT_DATA([means-missing.sps], [dnl
+data list notable list /a * b * g1.
+begin data.
+1 2 9  
+2 2 1 
+3 2 1 
+4 2 2 
+5 2 2 
+6 2 2 
+7 9 2 
+end data.
+
+MISSING VALUES a b g1 (9).
+
+MEANS a b BY g1 /cells =  COUNT .
+
+MEANS a b BY g1 /cells =  COUNT /missing = include .
+
+MEANS a b BY g1 /cells =  COUNT /missing = dependent .
+])
+
+
+AT_CHECK([pspp -O format=csv means-missing.sps], [0],
+  [dnl
+Table: Case Processing Summary
+,Cases,,,,,
+,Included,,Excluded,,Total,
+,N,Percent,N,Percent,N,Percent
+a: g1,6,85.7143%,1,14.2857%,7,100%
+b: g1,5,71.4286%,2,28.5714%,7,100%
+
+Table: Report
+,g1,N
+a,1.00,2.00
+,2.00,4.00
+b,1.00,2.00
+,2.00,3.00
+
+Table: Case Processing Summary
+,Cases,,,,,
+,Included,,Excluded,,Total,
+,N,Percent,N,Percent,N,Percent
+a: g1,7,100%,0,0%,7,100%
+b: g1,7,100%,0,0%,7,100%
+
+Table: Report
+,g1,N
+a,1.00,2.00
+,2.00,4.00
+,9.00,1.00
+b,1.00,2.00
+,2.00,4.00
+,9.00,1.00
+
+Table: Case Processing Summary
+,Cases,,,,,
+,Included,,Excluded,,Total,
+,N,Percent,N,Percent,N,Percent
+a: g1,7,100%,0,0%,7,100%
+b: g1,6,85.7143%,1,14.2857%,7,100%
+
+Table: Report
+,g1,N
+a,1.00,2.00
+,2.00,4.00
+,9.00,1.00
+b,1.00,2.00
+,2.00,3.00
+,9.00,1.00
+])
+
+AT_CLEANUP
+
+
+