/* File "discrim1.sas": class example from slides 6-12. Note comments in SAS are enclosed by "slash-star" and "star-slash." Import the discrim.xls data (use "discrim" for member), then select Solutions > Analysis > Analyst to look at the data graphically. First use File > Open By SAS Name to open "discrim" (which should be in the Work library). The following code runs a canonical discriminant analysis. At this stage, the relevant output includes "raw canonical coefficients" ("Z" in the notes), the "classification results" (giving probabilities of being in each group), and the "classification summary"; ignore all the other output for now. */ proc discrim canonical list data=work.discrim out=work.results; class cluster; var age exp sal; priors proportional; id id; run; /* A plot of the canonical discriminant function versus status provides some insight into what is going on. */ proc plot data=work.results; plot can1*cluster; run;