[R] drawing a plot with SEM

David Winsemius dwinsemius at comcast.net
Wed Apr 22 17:33:19 CEST 2009


I realized after looking again that you asked for plotting. Since you  
only have two points per row, it would be more honest statistically to  
plot the values rather than mean and sem.

 > dm <-read.table(textConnection("      repeat1    repeat2
+ 1        30            34
+ 2        12            23
+ 3         50           13
+ 4         56            98"), header=TRUE)
 > plot(x=1:nrow(dm), y=dm$repeat1, ylim=c(min(dm), max(dm))  )
 > points(x=1:nrow(dm), y=dm$repeat2)


On Apr 22, 2009, at 10:26 AM, ANJAN PURKAYASTHA wrote:

> I have a data matrix:
>        repeat1    repeat2
> 1        30            34
> 2        12            23
> 3         50           13
> 4         56            98
> .
>
> I would like to plot for the mean and standard error of mean of  
> repeat 1 and
> repeat2 for each row.
> Any pointers on how to do this in R?
>
> TIA,
> Anjan
> -- 
> =============================
> anjan purkayastha, phd
> bioinformatics analyst
> whitehead institute for biomedical research

David Winsemius, MD
Heritage Laboratories
West Hartford, CT




More information about the R-help mailing list