BINOMIAL Subcommand (NPAR TESTS command)
NPAR TESTS BINOMIAL [({.5})]=varlist[({value,value})]
{p } {value }
BINOMIAL
tests whether the observed distribution of a dichotomous variable
is the same as what is expected from a specified binomial distribution.
By default, each named variable is assumed to have only two values,
and the distribution of each named variable is compared to a binomial
distribution with p (the proportion
of cases expected in the first category) equal to 0.5. The default
output includes the number of valid cases in each group, the test
proportion, and the two-tailed probability of the observed proportion.
Syntax
- The minimum specification is a list of variables to be tested.
- To change the default 0.5 test proportion,
specify a value in parentheses immediately after keyword
BINOMIAL
. - A single value in parentheses following the variable list is used as a cutting point. Cases with values that are equal to or less than the cutting point form the first category; the remaining cases form the second category.
- If two values appear in parentheses after the variable list, cases with values that are equal to the first value form the first category, and cases with values that are equal to the second value form the second category.
- If no values are specified, the variables must be dichotomous. The first value encountered in the dataset defines the first category, and the other value defines the second category.
Operations
- The proportion observed in the first category is compared to the test proportion. The probability of the observed proportion occurring given the test proportion and a binomial distribution is then computed. A test statistic is calculated for each variable specified.
- If the test proportion is the default (0.5), a two-tailed probability is displayed. For any other test proportion, a one-tailed probability is displayed. The direction of the one-tailed test depends on the observed proportion in the first category. If the observed proportion is more than the test proportion, the significance of observing that many or more in the first category is reported. If the observed proportion is less than or equal to the test proportion, the significance of observing that many or fewer in the first category is reported. In other words, the test is always done in the observed direction.
Example
NPAR TESTS BINOMIAL(.667)=V1(0,1).
-
NPAR TESTS
displays the Binomial Test table, showing the number of cases, observed proportion, test proportion (0.667), and the one-tailed significance for each category. - If more than 0.667 of the
cases have value 0 for V1,
BINOMIAL
gives the probability of observing that many or more values of 0 in a binomial distribution with probability 0.667. If fewer than 0.667 of the cases are 0, the test will be of observing that many or fewer values.