- Mark as New
- Bookmark
- Subscribe
- Mute
- RSS Feed
- Permalink
- Report Inappropriate Content
Hi,
I have successfully executed the repeated measurement code. While using PROC PLM, I can visualize the mean separation by alphabet. However, the line graph generated by SAS is not what I wish to present in my thesis. Do you know how I can generate a line graph in SAS that looks similar to an Excel line graph that I show below?
Line graphs from SAS
Line graph from Excel
Code for repeated measurement
Data RM;
set RM;
TRL_new = TRL ;
TRL_sq = sqrt(TRL_new);
TRL_log = log(TRL_new+1);
run;
ods graphics on;
proc sort data= RM;
by EU Day;
run;
%LET type=un; /*"Using the unstructured covariance matrix" */
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;
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;
store ABCXYZ / label='PLM: Getting Started'; /* Store (Save the results from Proc Mixed) */
run;
proc plm restore=ABCXYZ; /* Use for Prost Hoc Analysis with PROC PLM */
lsmeans Irrigation*day / lines linestable; /* Use for Prost Hoc Analysis for irrigation and day factors*/
ods output LSMLines=LSMLines;
run;
/* end of program */
- Mark as New
- Bookmark
- Subscribe
- Mute
- RSS Feed
- Permalink
- Report Inappropriate Content
data have;
call streaminit(123);
do treat=1 to 2;
do day=25 to 60;
do i=1 to 20;
x=rand('uniform')+treat;output;
end;
end;
end;
run;
proc summary data=have nway;
class treat day;
var x;
output out=want mean=mean lclm=lclm uclm=uclm;
run;
proc sgplot data=want;
series x=day y=mean/group=treat markers markerattrs=(symbol=circlefilled);
scatter x=day y=mean/yerrorlower=lclm yerrorupper=uclm group=treat markerattrs=(size=0);
run;
- Mark as New
- Bookmark
- Subscribe
- Mute
- RSS Feed
- Permalink
- Report Inappropriate Content
- https://support.sas.com/sassamples/graphgallery/PROC_SGPLOT.html
- Sample 42542: Plot means with standard error bars from calculated data with PROC SGPLOT
https://support.sas.com/kb/42/542.html - Sample 35053: Mean percent change in allergy relief
https://support.sas.com/kb/35/053.html - Sample 35169: Stock chart
https://support.sas.com/kb/35/169.html
Koen