3 # This program tests that the T-TEST works when the independent
7 TEMPDIR=/tmp/pspp-tst-$$
8 TESTFILE=$TEMPDIR/`basename $0`.sps
12 # ensure that top_srcdir is absolute
13 cd $top_srcdir; top_srcdir=`pwd`
15 STAT_CONFIG_PATH=$top_srcdir/config
16 export STAT_CONFIG_PATH
53 activity="create program"
55 data list list /ID * INDEP (a1) DEP1 * DEP2 *.
71 t-test /GROUPS=indep('a','b') /var=dep1 dep2.
73 if [ $? -ne 0 ] ; then no_result ; fi
76 activity="run program"
77 $SUPERVISOR $here/../src/pspp -o raw-ascii $TESTFILE
78 if [ $? -ne 0 ] ; then no_result ; fi
80 activity="compare output"
81 diff -B -b $TEMPDIR/pspp.list - <<EOF
82 1.1 DATA LIST. Reading free-form data from the command file.
92 2.1 T-TEST. Group Statistics
93 #==========#=#====#==============#========#
94 # INDEP|N|Mean|Std. Deviation|SE. Mean#
95 #==========#=#====#==============#========#
96 #DEP1 a |5|2.00| .707| .316#
97 # b |5|4.00| .707| .316#
98 #DEP2 a |5|4.00| .707| .316#
99 # b |5|2.00| .707| .316#
100 #==========#=#====#==============#========#
102 2.2 T-TEST. Independent Samples Test
103 #===============================#==========#===============================================================================#
104 # # Levene's | t-test for Equality of Means #
105 # #----+-----+------+-----+---------------+---------------+---------------------+------------#
106 # # | | | | | | | 95% #
107 # # | | | | | | +------+-----#
108 # # F | Sig.| t | df |Sig. (2-tailed)|Mean Difference|Std. Error Difference| Lower|Upper#
109 #===============================#====#=====#======#=====#===============#===============#=====================#======#=====#
110 #DEP1Equal variances assumed #.000|1.000|-4.472| 8| .002| -2.000| .447|-3.031|-.969#
111 # Equal variances not assumed# | |-4.472|8.000| .002| -2.000| .447|-3.031|-.969#
112 #DEP2Equal variances assumed #.000|1.000| 4.472| 8| .002| 2.000| .447| .969|3.031#
113 # Equal variances not assumed# | | 4.472|8.000| .002| 2.000| .447| .969|3.031#
114 #===============================#====#=====#======#=====#===============#===============#=====================#======#=====#
116 if [ $? -ne 0 ] ; then fail ; fi