[R] barplots - text direction

From: Murray Pung <Murraypu_at_aimnsw.com.au>
Date: Wed 24 Aug 2005 - 11:27:20 EST


If the variable names are too long to allow room for each to be displayed on a barplot, how can the direction of the text be changed?

a <- cbind(2.4,2.4,2.5,2.6,2.6,2.6,2.6,2.6,2.9,2.9,2.9)
b <- cbind(2.3,2.5,2.4,2.2,3.2,2.4,2.9,2.6,2.9,3.0,2.8)
h <- rbind(a,b)

colnames(h) <- c("one","two","three","four","five","six","seven","eight","nine","ten","eleven") rownames(h) <- c("Pre-stage","Post-stage") barplot(h, beside = T, legend = colnames(g), horiz = T, xlim = c(0, 5))

Many Thanks
Murray

Murray Pung | Research Analyst
AIM Research & HR Consulting
PO Box 328, Nth Sydney NSW 2060
P +61 (02) 9956 3951
F +61 (02) 9922 2210
www.aimsurveys.com.au



R-help@stat.math.ethz.ch mailing list
https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html Received on Wed Aug 24 11:34:30 2005

This archive was generated by hypermail 2.1.8 : Fri 03 Mar 2006 - 03:39:55 EST