Ok, I think I solved this issues using this script: PROC PRINT DATA=WORK.MYEXCEL; RUN; PROC PRINT; RUN; data new1; set import (rename=data=date); keep date crop plot TX; run; proc print; run; proc sort data=new1; by crop plot; run; proc print; run; proc transpose out=New2; by crop plot; id date; run; proc print; run; data new3; set new2; drop _name_ _label_; run; proc print; run; PROC CONTENTS DATA=new3; RUN; PROC GLM data=new3; CLASS crop ; title "RH"; model _06JAN2015--_28DEC2015 = crop ; repeated time 20 (1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20) / summary printe; MEANS crop / lsd alpha=0.05; run; On a database that had 20 dates of measurements and it was structured like this (example with just 2 dates) Date Plot Crop TX 06-Jan-15 13 Wheat 0,1 06-Jan-15 15 Wheat 0,3 06-Jan-15 17 Wheat 0 06-Jan-15 19 Corn 0,1 06-Jan-15 21 Corn 0,65 06-Jan-15 23 Corn 0,95 06-Jan-15 25 Tobacco 0,1 06-Jan-15 27 Tobacco 0,1 06-Jan-15 29 Tobacco 0 03-Apr-15 13 Wheat 6,75 03-Apr-15 15 Wheat 5,8 03-Apr-15 17 Wheat 6,45 03-Apr-15 19 Corn 6,7 03-Apr-15 21 Corn 6,25 03-Apr-15 23 Corn 6,3 03-Apr-15 25 Tobacco 6,15 03-Apr-15 27 Tobacco 5,95 03-Apr-15 29 Tobacco 2,93
... View more