Biostat Macro Library

Kruskal-Wallis

%KrusWall resides in the departments SAS Macro Library and is enabled with the following SAS statements:

Libname biostat '\\BIO2\example\SASMacrosWindows';
Options Mstored SasMstore=biostat;

%KrusWall calls PROC NPAR1WAY to run the Kruskal-Wallis test on a list of dependent variables at each visit in the specified database. The output has been modified to include the Mean, Median, Quartiles, Standard Deviation and Standard Error.

Syntax:
%KrusWall(dataset,group,visit,varlist);
    dataset:    Dataset to use.
    group:      Class or treatment variable.(Numeric)
    visit:         Time variable: visit, week, month.(Numeric)
    varlist:      List of dependent variables.(Numeric)

Example:
%KrusWall(work.A,Treatment,Week,A B C D);

Output: