[R] ggplot rank stack bar automatically.

vd3000 vd3000 at yahoo.co.uk
Wed Feb 15 17:34:26 CET 2012


Hi, all, 

I am currently trying to learn this example. 
http://learnr.wordpress.com/2009/03/17/ggplot2-barplots/


I created the stack bar easily. 

If I would like to rank the stack bar from the highest on the right,
shortest on the left and eventually
I could show the data "1991-00" on the left and  "1823-30" on the right, how
could I do that? 

Apart from this, I find something quite weird,
If I import a data frame with column names containing \n, for example,
pretty\nwoman, lemon\ntree, etc
for example: f3=as.data.frame(read.table("f3.csv", sep=",", row.names=1,
header=TRUE, check.names=FALSE)) 
even I put check.names=FALSE, the column name will be changed to \\n, ie,
pretty\\nwoman, lemon\\ntree.
How could I get rid of extra "\"  sign ???



Hope some genius could help. 

Thanks in advance. 

vd  



--
View this message in context: http://r.789695.n4.nabble.com/ggplot-rank-stack-bar-automatically-tp4391042p4391042.html
Sent from the R help mailing list archive at Nabble.com.



More information about the R-help mailing list