Google
 

Trailing-Edge - PDP-10 Archives - decus_20tap2_198111 - decus/20-0026/tie.doc
There are 2 other files named tie.doc in the archive. Click here to see a list.
SUBROUTINE TIE

PURPOSE
   CALCULATE CORRECTION FACTOR DUE TO TIES

USAGE
   CALL TIE(R,N,KT,T)

DESCRIPTION OF PARAMETERS
   R  - INPUT VECTOR OF RANKS OF LENGTH N CONTAINING VALUES
	1 TO N
   N  - NUMBER OF RANKED VALUES
   KT - INPUT CODE FOR CALCULATION OF CORRECTION FACTOR
	      1   SOLVE EQUATION 1
	      2   SOLVE EQUATION 2
   T  - CORRECTION FACTOR (OUTPUT)
	    EQUATION 1	 T=SUM(CT**3-CT)/12
	    EQUATION 2	 T=SUM(CT*(CT-1)/2)
	  WHERE CT IS THE NUMBER OF OBSERVATIONS TIED FOR A
		GIVEN RANK

REMARKS
   NONE

SUBROUTINES AND FUNCTION SUBPROGRAMS REQUIRED
   NONE

METHOD
   VECTOR IS SEARCHED FOR SUCCESSIVELY LARGER RANKS. TIES ARE
   COUNTED AND CORRECTION FACTOR 1 OR 2 SUMMED.