Date: Wed, 3 Jan 2001 21:28:25 GMT
Reply-To: John Uebersax <jsuebersax@MY-DEJA.COM>
Sender: "SAS(r) Discussion" <SAS-L@LISTSERV.UGA.EDU>
From: John Uebersax <jsuebersax@MY-DEJA.COM>
Subject: Re: adding std. error bars to plot?
Thanks John (Hixon).
The info you posted is informative, but there's a twist. I only want
to show the mean value (and standard error bar) at each week, but not
the values for individual patients. If I understand it, your example
below would plot a point for each case. Do you know of a way to plot
only, say, a circle for each mean, and a standard error bar through the
circle at each week?
Incidentally, I have also calculated the means and standard errors in a
separate proc, so perhaps these can be used to provide std error bars
in some alternative approach.
In article <852569C9.006FBCA6.firstname.lastname@example.org>,
> From: John Hixon
> John asked:
> >Date: Wed, 3 Jan 2001 19:52:31 GMT
> >From: John Uebersax <jsuebersax@MY-DEJA.COM>
> >Subject: adding std. error bars to plot?
> >I would like to add vertical bars reflecting the standard error of
> >mean to a plot for the mean value of X over time. Can someone
> >how to do this within the context of proc gplot? thanks in advance.
> >John Uebersax
> Use the interpolate option for the symbol. Look up the syntax
> for all kinds of options. The code below generates an error bar
> that is 2*StdError of the Mean. You could use 1 SE or 3 SEs etc.
> Have fun.
> * generate some phony data with 5 groups;
> data sample;
> do group=1 to 5;
> do num_samples=ceil(500+100*ranuni(-1));
> do i=1 to num_samples;
> * make the plot and automatically add std error bars;
> symbol1 c=blue v=none i=std2tj;
> proc gplot data=sample;
> plot response*group ;
> I hope this is helpful. The i=option can do some wonderful things
> on its own, but...nothing replaces a complete analysis of the data
> using Proc Mixed, GLM, or whathaveyou... :-)
> Best regards,
> John Hixon
> Eastman Kodak Company
> Rochester, NY USA
Sent via Deja.com