Add tty and listing devices that use VT100 (and xterm) line-drawing
[pspp-builds.git] / doc / statistics.texi
index 0774d526d70653fbac37c0dbf2c416c763d76972..7c141fa50068c555789c2f4e82fdfc1ca6860fe6 100644 (file)
@@ -1,4 +1,4 @@
-@node Statistics, Utilities, Conditionals and Looping, Top
+@node Statistics
 @chapter Statistics
 
 This chapter documents the statistical procedures that PSPP supports so
@@ -9,13 +9,14 @@ far.
 * FREQUENCIES::                 Frequency tables.
 * EXAMINE::                     Testing data for normality.
 * CROSSTABS::                   Crosstabulation tables.
+* NPAR TESTS::                  Nonparametric tests.
 * T-TEST::                      Test hypotheses about means.
 * ONEWAY::                      One way analysis of variance.
 * RANK::                        Compute rank scores.
 * REGRESSION::                  Linear regression.
 @end menu
 
-@node DESCRIPTIVES, FREQUENCIES, Statistics, Statistics
+@node DESCRIPTIVES
 @section DESCRIPTIVES
 
 @vindex DESCRIPTIVES
@@ -105,7 +106,7 @@ in the order that they are specified on the VARIABLES subcommand.  The A
 and D settings request an ascending or descending sort order,
 respectively.
 
-@node FREQUENCIES, EXAMINE, DESCRIPTIVES, Statistics
+@node FREQUENCIES
 @section FREQUENCIES
 
 @vindex FREQUENCIES
@@ -229,7 +230,7 @@ slices.  The MINIMUM and MAXIMUM keywords can be used to limit the
 displayed slices to a given range of values.  The MISSING keyword adds
 slices for missing values.
 
-@node EXAMINE, CROSSTABS, FREQUENCIES, Statistics
+@node EXAMINE
 @comment  node-name,  next,  previous,  up
 @section EXAMINE
 @vindex EXAMINE
@@ -304,7 +305,7 @@ there are many distinct values, then @cmd{EXAMINE} will produce a very
 large quantity of output.
 
 
-@node CROSSTABS, T-TEST, EXAMINE, Statistics
+@node CROSSTABS
 @section CROSSTABS
 
 @vindex CROSSTABS
@@ -493,11 +494,122 @@ Approximate T of uncertainty coefficient is wrong.
 
 Fixes for any of these deficiencies would be welcomed.
 
-@node T-TEST, ONEWAY, CROSSTABS, Statistics
+@node NPAR TESTS
+@section NPAR TESTS
+
+@vindex NPAR TESTS
+@cindex nonparametric tests
+
+@display 
+NPAR TESTS
+     
+     nonparametric test subcommands
+     .
+     .
+     .
+     
+     [ /STATISTICS=@{DESCRIPTIVES@} ]
+
+     [ /MISSING=@{ANALYSIS, LISTWISE@} @{INCLUDE, EXCLUDE@} ]
+@end display
+
+NPAR TESTS performs nonparametric tests. 
+Non parametric tests make very few assumptions about the distribution of the 
+data.
+One or more tests may be specified by using the corresponding subcommand.
+If the /STATISTICS subcommand is also specified, then summary statistics are 
+produces for each variable that is the subject of any test.
+
+
+@menu
+* BINOMIAL::                Binomial Test
+* CHISQUARE::               Chisquare Test
+@end menu
+
+
+@node    BINOMIAL
+@subsection Binomial test
+@vindex BINOMIAL
+@cindex binomial test
+
+@display 
+     [ /BINOMIAL[(p)]=var_list[(value1[, value2)] ] ]
+@end display 
+
+The binomial test compares the observed distribution of a dichotomous 
+variable with that of a binomial distribution.
+The variable @var{p} specifies the test proportion of the binomial 
+distribution.  
+The default value of 0.5 is assumed if @var{p} is omitted.
+
+If a single value appears after the variable list, then that value is
+used as the threshold to partition the observed values. Values less
+than or equal to the threshold value form the first category.  Values
+greater than the threshold form the second category. 
+
+If two values appear after the variable list, then they will be used
+as the values which a variable must take to be in the respective
+category. 
+Cases for which a variable takes a value equal to neither of the specified  
+values, take no part in the test for that variable.
+
+If no values appear, then the variable must assume dichotomous
+values.
+If more than two distinct, non-missing values for a variable
+under test are encountered then an error occurs.
+
+If the test proportion is equal to 0.5, then a one tailed test is
+reported.   For any other test proportion, a one tailed test is
+reported.   
+For one tailed tests, if the test proportion is less than
+or equal to the observed proportion, then the significance of
+observing the observed proportion or more is reported.
+If the test proportion is more than the observed proportion, then the
+significance of observing the observed proportion or less is reported.
+That is to say, the test is always performed in the observed
+direction. 
+
+PSPP uses a very precise approximation to the gamma function to
+compute the binomial significance.  Thus, exact results are reported
+even for very large sample sizes.
+
+
+
+@node    CHISQUARE
+@subsection Chisquare test
+@vindex CHISQUARE
+@cindex chisquare test
+
+
+@display
+     [ /CHISQUARE=var_list[(lo,hi)] [/EXPECTED=@{EQUAL|f1, f2 @dots{} fn@}] ]
+@end display 
+
+
+The chisquare test produces a chi-square statistic for the differences 
+between the expected and observed frequencies of the categories of a variable. 
+Optionally, a range of values may appear after the variable list.  
+If a range is given, then non integer values are truncated, and values
+outside the  specified range are excluded from the analysis.
+
+The /EXPECTED subcommand specifies the expected values of each
+category.  
+There must be exactly one non-zero expected value, for each observed
+category, or the EQUAL keywork must be specified.
+You may use the notation @var{n}*@var{f} to specify @var{n}
+consecutive expected categories all taking a frequency of @var{f}.
+The frequencies given are proportions, not absolute frequencies.  The
+sum of the frequencies need not be 1.
+If no /EXPECTED subcommand is given, then then equal frequencies 
+are expected.
+
+
+@node T-TEST
 @comment  node-name,  next,  previous,  up
 @section T-TEST
 
 @vindex T-TEST
+
 @display
 T-TEST
         /MISSING=@{ANALYSIS,LISTWISE@} @{EXCLUDE,INCLUDE@}
@@ -558,7 +670,7 @@ which they would be needed. This is the default.
 * Paired Samples Mode::         Testing two interdependent groups for equal mean
 @end menu
 
-@node One Sample Mode, Independent Samples Mode, T-TEST, T-TEST
+@node One Sample Mode
 @subsection One Sample Mode
 
 The @cmd{TESTVAL} subcommand invokes the One Sample mode.
@@ -569,7 +681,7 @@ which you wish to test.
 In this mode, you must also use the @cmd{/VARIABLES} subcommand to
 tell PSPP which variables you wish to test.
 
-@node Independent Samples Mode, Paired Samples Mode, One Sample Mode, T-TEST
+@node Independent Samples Mode
 @comment  node-name,  next,  previous,  up
 @subsection Independent Samples Mode
 
@@ -597,14 +709,14 @@ the independent variable are excluded on a listwise basis, regardless
 of whether @cmd{/MISSING=LISTWISE} was specified.
 
 
-@node Paired Samples Mode,  , Independent Samples Mode, T-TEST
+@node Paired Samples Mode
 @comment  node-name,  next,  previous,  up
 @subsection Paired Samples Mode
 
 The @cmd{PAIRS} subcommand introduces Paired Samples mode.
 Use this mode when repeated measures have been taken from the same
 samples.
-If the the @code{WITH} keyword is omitted, then tables for all
+If the @code{WITH} keyword is omitted, then tables for all
 combinations of variables given in the @cmd{PAIRS} subcommand are
 generated. 
 If the @code{WITH} keyword is given, and the @code{(PAIRED)} keyword
@@ -618,7 +730,7 @@ of variable preceding @code{WITH} against variable following
 @code{WITH} are generated.
 
 
-@node ONEWAY, RANK, T-TEST, Statistics
+@node ONEWAY
 @comment  node-name,  next,  previous,  up
 @section ONEWAY
 
@@ -668,7 +780,7 @@ The @code{CONTRASTS} subcommand may be given up to 10 times in order
 to specify different contrast tests.
 @setfilename ignored
 
-@node RANK, REGRESSION, ONEWAY, Statistics
+@node RANK
 @comment  node-name,  next,  previous,  up
 @section RANK