Hi, I'm struggling with errbar graphics.

I'm trying to plot an x-y graph with correct labelling, however can't seem
to get main and sub to show on my graph. 

They do work when I use title(main="," etc...., but this will make it look
at lot messier,I'll have to blank out ylab=" " , and I need to try and get
the titles to update automatically according to my excel column headings and
paste function.

Example code....

require(Hmisc)
data1<-array(sample(1:100,35),dim=c(5,7))
data1[,1]<-1:5
sd=apply(data1[,2:7],1,sd)
mean=rowMeans(data1[,2:7])
#the base plot works
errbar(x=data1[,1],y=mean,yplus=mean+sd,yminus=mean-sd)
#titles are shown correctly using plot
plot(x=data1[,1],y=mean,ylab="value",xlab="time",main="Title",sub="subtitle")
#the ylab and xlab update correctly, however main and sub don't?
errbar(x=data1[,1],y=mean,yplus=mean+sd,yminus=mean-sd,ylab="value",xlab="time",main="Title",sub="subtitle")

(my original is a lot more complicated as I'm reading from excel, and have
managed to plot SD and mean for my dataset, but for some reason the main and
sub commands aren't working in errbar!)

Thanks,

Laura



--
View this message in context: 
http://r.789695.n4.nabble.com/Titles-main-and-subtitle-won-t-plot-with-errbar-tp4655149.html
Sent from the R help mailing list archive at Nabble.com.

______________________________________________
R-help@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
and provide commented, minimal, self-contained, reproducible code.

Reply via email to