![]() |
VAN DER WAERDEN SCOREName:
where \( R_{j} \) is the rank of the j-th observation, n is the number of observations and \( \Phi^{-1} \) is the percent point function of the normal distribution. Van der Waerden scores are used in the VAN DER WAERDEN command to test whether k samples have equal location. This test is an alternative to the Kruskal Wallis test.
<SUBSET/EXCEPT/FOR qualification> where <y> is the response variable; <s> is a variable where the computed Van der Waerden scores are saved; and where the <SUBSET/EXCEPT/FOR qualification> is optional.
. Step 1: Define the data . let y1 = data 16.55 15.36 15.94 16.43 16.01 let y2 = data 16.05 15.98 16.10 15.88 15.91 let n1 = size y1 let n2 = size y2 let n = n1 + n2 . . Step 2: Combine into single array . let y tag = stack y1 y2 if n1 <= n2 let tag = tag - 1 let n1t = n1 else let tag = 0 subset tag = 2 let n1t = n2 end of if . . Step 3: Compute the Van der Waerden scores . let vscore = van der waerden scores y . . Step 4: Two-Sample Linear Rank Test . let temp = tag*vscore let s = sum temp . let aval = sum ymood let smean = (n1t/n)*aval let meanrank = mean vscore let temp = (vscore - meanrank)**2 let aval = sum temp let svar = ((n1*n2)/(n*(n-1)))*aval let statval = (s - smean)/sqrt(svar) let statval = round(statval,3) let cv = norppf(0.975) let upplim = round(cv,2) let lowlim = -upplim feedback off print "Two Sample Linear Rank Sum Test Based on Van der Waerden Scores" print "H0: Locations are Equal" print "Ha: Locations are Not Equal" print "alpha: 0.05" print "Test Statistic: ^statval" print "Lower Critical Value: ^lowlim" print "Upper Critical Value: ^upplim" if statval < cv print "Conclusion: Accept H0" else print "Conclusion: Reject H0" end of ifThe following output is generated
Date created: 07/14/2023 |
Last updated: 07/14/2023 Please email comments on this WWW page to alan.heckert@nist.gov. |