3 # This program tests that the T-TEST /GROUPS command works properly
4 # when a single value in the independent variable is given.
6 TEMPDIR=/tmp/pspp-tst-$$
7 TESTFILE=$TEMPDIR/`basename $0`.sps
11 # ensure that top_srcdir is absolute
12 cd $top_srcdir; top_srcdir=`pwd`
14 STAT_CONFIG_PATH=$top_srcdir/config
15 export STAT_CONFIG_PATH
51 activity="create program"
53 data list list /INDEP * DEP *.
78 t-test /groups=indep(1.514) /var=dep.
80 if [ $? -ne 0 ] ; then no_result ; fi
83 activity="run program"
84 $SUPERVISOR $here/../src/pspp -o raw-ascii $TESTFILE
85 if [ $? -ne 0 ] ; then no_result ; fi
88 activity="compare output"
89 diff -B -b $TEMPDIR/pspp.list - <<EOF
90 1.1 DATA LIST. Reading free-form data from the command file.
98 2.1 T-TEST. Group Statistics
99 #===========#==#====#==============#========#
100 # INDEP | N|Mean|Std. Deviation|SE. Mean#
101 #===========#==#====#==============#========#
102 #DEP < 1.514|11|8.00| 2.864| .863#
103 # >=1.514|11|9.00| 3.821| 1.152#
104 #===========#==#====#==============#========#
106 2.2 T-TEST. Independent Samples Test
107 #==============================#=========#===============================================================================#
108 # #Levene's | t-test for Equality of Means #
109 # #----+----+-----+------+---------------+---------------+---------------------+------------#
110 # # | | | | | | | 95% #
111 # # | | | | | | +------+-----#
112 # # F |Sig.| t | df |Sig. (2-tailed)|Mean Difference|Std. Error Difference| Lower|Upper#
113 #==============================#====#====#=====#======#===============#===============#=====================#======#=====#
114 #DEPEqual variances assumed #.172|.683|-.695| 20| .495| -1.000| 1.440|-4.003|2.003#
115 # Equal variances not assumed# | |-.695|18.539| .496| -1.000| 1.440|-4.018|2.018#
116 #==============================#====#====#=====#======#===============#===============#=====================#======#=====#
118 if [ $? -ne 0 ] ; then fail ; fi