10-05-2016 05:05 AM
Based on documentation Van elteren test can be computed using PROC FREQ and PROC NPAR1WAY. However, the results are different. Why is this so? Is there a case where the two are equal?
proc npar1way wilcoxon correct=no data=SimR2;
label "VAN ELTEREN TEST - NPAR1WAY ";
class trt strata;
STRATA stratavar /weight=STRATA;
ods output WilcoxonStrataTest=VanElterenTest
proc freq data=SimR2;
title ' Van Elteren test with PROC FREQ';
ods select cmh;
tables trt*stratavar*counts/cmh2 scores=modridit; /* Row Mean Scores Difference is the van elteren statistic*/
ods output cmh=VanElt;
10-05-2016 07:46 AM
It looks like you are doing two different statistic method. First is Wilcoxon test which compare two level's mean value. Second is Freedman Test which compare more than two level's mean value . Your code is not right, you should put COUNT into WEIGHT statement.
10-05-2016 04:35 PM
It looks like you have the position of the strata and treatment variables reversed in the FREQ step. See this example that shows the analysis using FREQ. You get the same results with these statements: