Biostat Macro LibraryMass Production of Chi-Square Tests%GroupSize and %Chisq reside in the departments SAS Macro Library and are enabled with the following SAS statements: L %GroupSize and %Chisq work together to count the number of events by treatment group, and calculate Chi-square tests between the groups. %GroupSize must be called first to set up some global macro variables that hold the size of each treatment group. The dataset passed to %GroupSize must have only one observation per subject. The dataset passed to %Chisq must have one observation for each event reported. Three batteries of Chi-square test may be done: All combinations(A-B,A-C,A-D,B-C,B-D,C-D), Dosage response(A-B,A-C,A-D), or TwoByTwo design(AB-CD,AC-BD,AD-BC). Chi-square test are done on the number of subjects experiencing events, not the number of events reported. (If a subject reports “headache” four times, it is only counted once.) The percent experiencing in each group may be suppressed from the report to save space. Syntax: %Chisq(datasetB,who,by,group,request,percents); Example: Output:
|
|||