SED navigation bar go to SED home page go to Dataplot home page go to NIST home page SED Home Page SED Staff SED Projects SED Products and Publications Search SED Pages
Dataplot Vol 1 Vol 2

POISSON DISPERSION TEST

Name:
    POISSON DISPERSION TEST
Type:
    Analysis Command
Purpose:
    Perform a Poisson dispersion test for Poissonality.
Description:
    The Poisson dispersion test is one of the most common tests to determine if a univariate data set follows a Poisson distribution.

    The Poisson dispersion test statistic is defined as:

      \[ D = \sum_{i=1}^{N}{\frac{(X_{i} - \bar{X})^2} {\bar{X}}} \]

    with \(\bar{X}\) and N denoting the sample mean and the sample size, respectively.

    Note that this test can be applied to either raw (ungrouped) data or to frequency (grouped) data.

    This test follows an approximately chi-square distribution with N - 1 degrees of freedom. This is a two-tailed test.

Syntax 1:
    POISSON DISPERSION TEST <y>             <SUBSET/EXCEPT/FOR qualification>
    where <y> is the response variable;
    and where the <SUBSET/EXCEPT/FOR qualification> is optional.

    This syntax is used for the raw (ungrouped) data case.

Syntax 2:
    POISSON DISPERSION TEST <y> <x>             <SUBSET/EXCEPT/FOR qualification>
    where <y> is the variable containing the frequencies;
                <x> is the variable containing the class mid-points;
    and where the <SUBSET/EXCEPT/FOR qualification> is optional.

    This syntax is used for the grouped data case.

Syntax 3:
    MULTIPLE POISSON DISPERSION TEST <y1> ... <yk>
                            <SUBSET/EXCEPT/FOR qualification>
    where <y1> ... <yk> is a list of 1 to 30 response variables;
    and where the <SUBSET/EXCEPT/FOR qualification> is optional.

    This syntax performs a Poisson dispersion test on <y1> then on <y2> and so on. Up to 30 response variables may be specified.

    Note that the syntax

      MULTIPLE POISSON DISPERSION TEST Y1 TO Y4

    is supported. This is equivalent to

      MULTIPLE POISSON DISPERSION TEST Y1 Y2 Y3 Y4
Syntax 4:
    REPLICATED POISSON DISPERSION TEST <y> <x1> ... <xk>
                            <SUBSET/EXCEPT/FOR qualification>
    where <y> is the response variable;
                <x1> ... <xk> is a list of 1 to 6 group-id variables;
    and where the <SUBSET/EXCEPT/FOR qualification> is optional.

    This syntax peforms a cross-tabulation of <x1> ... <xk> and performs a Poisson dispersion test for each unique combination of cross-tabulated values. For example, if X1 has 3 levels and X2 has 2 levels, there will be a total of 6 Poisson dispersion tests performed.

    Up to six group-id variables can be specified.

    Note that the syntax

      REPLICATED POISSON DISPERSION TEST Y X1 TO X4

    is supported. This is equivalent to

      REPLICATED POISSON DISPERSION TEST Y X1 X2 X3 X4
Examples:
    POISSON DISPERSION TEST Y1
    POISSON DISPERSION TEST Y1 SUBSET TAG > 2
    MULTIPLE POISSON DISPERSION TEST Y1 TO Y10
    REPLICATED POISSON DISPERSION TEST Y X
Note:
    Syntax 1 and Syntax 3 support matrix arguments. Syntax 3 and Syntax 4 support the TO syntax.

    For Syntax 4 (the REPLICATED form), the variables must all have the same number of observations.

Note:
    The following statistics are also supported:

      LET A = POISSON DISPERSION TEST Y
      LET A = POISSON DISPERSION TEST CDF Y
      LET A = POISSON DISPERSION TEST PVALUE Y

      LET A = GROUPED POISSON DISPERSION TEST Y X
      LET A = GROUPED POISSON DISPERSION TEST CDF Y X
      LET A = GROUPED POISSON DISPERSION TEST PVALUE Y X

    In addition to the above LET command, built-in statistics are supported for about 20 different commands (enter HELP STATISTICS for details).

Note:
    The POISSON DISPERSION TEST command automatically saves the following internal parameters:

      STATVAL: the value of the test statistic
      STATCDF: the CDF of the test statistic
      PVALUE: the p-value for the two-sided test
      CUTLOW50: the 50% lower tailed critical value
      CUTUPP50: the 50% upper tailed critical value
      CUTLOW80: the 80% lower tailed critical value
      CUTUPP80: the 80% upper tailed critical value
      CUTLOW90: the 90% lower tailed critical value
      CUTUPP90: the 90% upper tailed critical value
      CUTLOW95: the 95% lower tailed critical value
      CUTUPP95: the 95% upper tailed critical value
      CUTLOW99: the 99% lower tailed critical value
      CUTUPP99: the 99% upper tailed critical value
      CUTLO999: the 99.9% lower tailed critical value
      CUTUP999: the 99.9% upper tailed critical value

    If the MULTIPLE or REPLICATED option is used, these values will be written to the file "dpst1f.dat" instead.

Default:
    None
Synonyms:
    None
Related Commands:
    POISSON PLOT = Generate a Poisson plot.
    GOODNESS OF FIT = Perform Anderson-Darling, Kolmogorov-Smirnov, Chi-Square, and PPCC goodness of fit tests.
    POIPDF = Compute the Poisson probability mass function.
Reference:
    Spinelli and Stephens (1997), "Cramer-Von Mises Tests of Fit for the Poisson Distribution," Canadian Journal of Statistics, Vol. 25(2), pp. 257-267.

    Kendell and Stuart (1979), "The Advanced Theory of Statistics: Volume 2," Fourth Edition, Griffin, London.

Applications:
    Distributional Fitting
Implementation Date:
    2013/11
Program 1:
     
    LET LAMBDA = 25
    LET Y = POISSON RANDOM NUMBERS FOR I = 1 1 1000
    SET WRITE DECIMALS 4
    POISSON DISPERSION TEST Y
        
    The following output is generated
                Poisson Dispersion Test
     
    Response Variable: Y
     
    H0: Data Are Poisson Distributed
    Ha: Data Are Not Poisson Distributed
     
    Summary Statistics:
    Number of Observations:                            1000
    Sample Mean:                                    24.7929
    Sample Standard Deviation:                       4.9834
    Sample Variance:                                24.8349
     
    Test Statistic Value:                         1000.6917
    Degrees of Freedom:                                 999
    CDF Value:                                       0.5210
    P-Value (2-tailed test):                         0.9579
     
     
                Two-Tailed Test
     
    H0: Poisson; Ha: Not Poisson
    ---------------------------------------------------------------------------
                                            Lower          Upper           Null
       Significance           Test       Critical       Critical     Hypothesis
              Level      Statistic          Value          Value     Conclusion
    ---------------------------------------------------------------------------
              50.0%      1000.6917       968.4986      1028.7747         ACCEPT
              80.0%      1000.6917       942.1612      1056.6952         ACCEPT
              90.0%      1000.6917       926.6311      1073.6426         ACCEPT
              95.0%      1000.6917       913.3009      1088.4870         ACCEPT
              99.0%      1000.6917       887.6211      1117.8904         ACCEPT
              99.9%      1000.6917       858.4350      1152.6642         ACCEPT
        
Program 2:
     
    . Step 1: Read the data
    .
    .         This data set is from:
    .
    .         Spinelli and Stephens (1997), "Cramer-Von Mises Tests of Fit
    .         for the Poisson Distribution", Canadian Journal of Statistics,
    .         Vol. 25(2).
    .
    .         Hoaglin (1980), "A Poissonness Plot", The American Statistician,
    .         34, pp. 146-149.
    .
    .         Note that there is an error in one of the entries in the Spinelli
    .         and Stephens (for cell 2, they give a value of 283 rather than the
    .         value of 383, their computed statistics are consistent with using
    .         the value 383).
    .
    read x2 y2
     0   57
     1  203
     2  383
     3  525
     4  532
     5  408
     6  273
     7  139
     8   45
     9   27
    10   10
    11    4
    12    0
    13    1
    14    1
    end of data
    .
    . Step 2: Perform the Poisson Dispersion test.
    .
    set write decimals 4
    poisson dispersion test y2 x2
        
    The following output is generated
                 Poisson Dispersion Test
      
     Frequency Variable:       Y2
     Class Mid-Point Variable: X2
      
     H0: Data Are Poisson Distributed
     Ha: Data Are Not Poisson Distributed
      
     Summary Statistics:
     Number of Observations:                            2608
     Sample Mean:                                     3.8715
     Sample Standard Deviation:                       1.9947
     Sample Variance:                                 3.9789
      
     Test Statistic Value:                         2488.9181
     Degrees of Freedom:                                2607
     CDF Value:                                       0.0493
     P-Value (2-tailed test):                         0.0986
      
      
                 Two-Tailed Test
      
     H0: Poisson; Ha: Not Poisson
     ---------------------------------------------------------------------------
                                             Lower          Upper           Null
        Significance           Test       Critical       Critical     Hypothesis
               Level      Statistic          Value          Value     Conclusion
     ---------------------------------------------------------------------------
               50.0%      2488.9181      2557.9398      2655.3334         REJECT
               80.0%      2488.9181      2514.9004      2699.9559         REJECT
               90.0%      2488.9181      2489.3762      2726.8977         REJECT
               95.0%      2488.9181      2467.3785      2750.4098         ACCEPT
               99.0%      2488.9181      2424.7621      2796.7504         ACCEPT
               99.9%      2488.9181      2375.9290      2851.1727         ACCEPT
        
Date created: 12/11/2013
Last updated: 12/11/2023

Please email comments on this WWW page to alan.heckert@nist.gov.