Trailing-Edge
-
PDP-10 Archives
-
decus_20tap2_198111
-
decus/20-0026/kolm.doc
There are 2 other files named kolm.doc in the archive. Click here to see a list.
SUBROUTINE KOLM2
PURPOSE
TESTS THE DIFFERENCE BETWEEN TWO SAMPLE DISTRIBUTION
FUNCTIONS USING THE KOLMOGOROV-SMIRNOV TEST
USAGE
CALL KOLM2(X,Y,N,M,Z,PROB)
DESCRIPTION OF PARAMETERS
X - INPUT VECTOR OF N INDEPENDENT OBSERVATIONS. ON
RETURN FROM KOLM2, X HAS BEEN SORTED INTO A
MONOTONIC NON-DECREASING SEQUENCE.
Y - INPUT VECTOR OF M INDEPENDENT OBSERVATIONS. ON
RETURN FROM KOLM2, Y HAS BEEN SORTED INTO A
MONOTONIC NON-DECREASING SEQUENCE.
N - NUMBER OF OBSERVATIONS IN X
M - NUMBER OF OBSERVATIONS IN Y
Z - OUTPUT VARIABLE CONTAINING THE GREATEST VALUE WITH
RESPECT TO THE SPECTRUM OF X AND Y OF
SQRT((M*N)/(M+N))*ABS(FN(X)-GM(Y)) WHERE
FN(X) IS THE EMPIRICAL DISTRIBUTION FUNCTION OF THE
SET (X) AND GM(Y) IS THE EMPIRICAL DISTRIBUTION
FUNCTION OF THE SET (Y).
PROB - OUTPUT VARIABLE CONTAINING THE PROBABILITY OF
THE STATISTIC BEING GREATER THAN OR EQUAL TO Z IF
THE HYPOTHESIS THAT X AND Y ARE FROM THE SAME PDF IS
TRUE. E.G., PROB= 0.05 IMPLIES THAT ONE CAN REJECT
THE NULL HYPOTHESIS THAT THE SETS X AND Y ARE FROM
THE SAME DENSITY WITH 5 PER CENT PROBABILITY OF BEING
INCORRECT. PROB = 1. - SMIRN(Z).
REMARKS
N AND M SHOULD BE GREATER THAN OR EQUAL TO 100. (SEE THE
MATHEMATICAL DESCRIPTION FOR THIS SUBROUTINE AND FOR THE
SUBROUTINE SMIRN, CONCERNING ASYMPTOTIC FORMULAE).
DOUBLE PRECISION USAGE---IT IS DOUBTFUL THAT THE USER WILL
WISH TO PERFORM THIS TEST USING DOUBLE PRECISION ACCURACY.
IF ONE WISHES TO COMMUNICATE WITH KOLM2 IN A DOUBLE
PRECISION PROGRAM, HE SHOULD CALL THE FORTRAN SUPPLIED
PROGRAM SNGL(X) PRIOR TO CALLING KOLM2, AND CALL THE
FORTRAN SUPPLIED PROGRAM DBLE(X) AFTER EXITING FROM KOLM2.
(NOTE THAT SUBROUTINE SMIRN DOES HAVE DOUBLE PRECISION
CAPABILITY AS SUPPLIED BY THIS PACKAGE.)
SUBROUTINES AND FUNCTION SUBPROGRAMS REQUIRED
SMIRN
METHOD
FOR REFERENCE, SEE (1) W. FELLER--ON THE KOLMOGOROV-SMIRNOV
LIMIT THEOREMS FOR EMPIRICAL DISTRIBUTIONS--
ANNALS OF MATH. STAT., 19, 1948. 177-189,
(2) N. SMIRNOV--TABLE FOR ESTIMATING THE GOODNESS OF FIT
OF EMPIRICAL DISTRIBUTIONS--ANNALS OF MATH. STAT., 19,
1948. 279-281.
(3) R. VON MISES--MATHEMATICAL THEORY OF PROBABILITY AND
STATISTICS--ACADEMIC PRESS, NEW YORK, 1964. 490-493,
(4) B.V. GNEDENKO--THE THEORY OF PROBABILITY--CHELSEA
PUBLISHING COMPANY, NEW YORK, 1962. 384-401.