Thank you for the information. I did the extra codes in my code but I got an error showing ! %pdmix612(DIFFSDATASET, LSMEANSDATASET, alpha=0.05, sort=NO, worksize=1); Error; incoccerct5INCLUDE statement will not be executed. There is a syntax error. WARNING: Apparent invocation of macro PDMIX612 not resolved. Do you know what is happening? Data RM; set RM; A_new = A + 1; A_sq = sqrt(A_new); A_log = log(A_new); run; ods graphics on; proc sort data= RM; by EU Day; run; %macro one(type); proc mixed data= RM cl plots=residualpanel (conditional) plot=boxplot (conditional); class Block Day Accession Irrigation EU; model A_new = Accession Day Irrigation Accession*Day Accession*Irrigation Irrigation*Day Accession*Irrigation*Day / ddfm=satterth; /*Satterthwaite ddf are requested. Without this specification, Proc Mixed may give erroneous ddf for repeated measures,*/ Random Block; repeated Day / subject=EU type=&type r rcorr; lsmeans Accession Day Irrigation Accession*Day Accession*Irrigation Irrigation*Day Accession*Irrigation*Day/adjust=Tukey pdiff; /* Save LSMEANS into a dataset (e.g., LSMEANSDATASET) */ make lsmeans out=LSMEANSDATASET noprint; /* Save pairwise differences into a dataset (e.g., DIFFSDATASET) */ make diffs out=DIFFSDATASET noprint; run; /* Include the external macro %pdmix612 and call it to perform letter annotation */ %include A:PDMIX612.SAS; %pdmix612(DIFFSDATASET, LSMEANSDATASET, alpha=0.05, sort=NO, worksize=1); %mend one; /*"%mend" indicates the end of the macro*/ %one(un); /*each time we write "%one" we are calling up the macro and running it with the type of Covariance structure designated in the parenthesis. For example, on this line we are saying, "Run the macro "one" using the unstructured covariance matrix" ("unstructured" means all variances and covariances are estimated separately) */ /*%one(ar(1)); */ /*%one(arh(1)); */ /*%one(toep); */ /*%one(toeph); */ %one(ante(1)); run; ods graphics off;
... View more