Re: [R] label_wrap_gen question

2012-08-08 Thread vd3000
Hi, Brian So, I could only rename the label by myself such as Light and heavy\ngood vehicles (diesel) -\nGVX in order to get Light and heavy good vehicles (diesel) - GVX Right? -- View this message in context: http://r.789695.n4.nabble.com/label-wrap-gen-question-tp4639364p4639539.htm

[R] label_wrap_gen question

2012-08-06 Thread vd3000
Hi, all I am trying to use the label_wrap_gen function in this website. https://github.com/hadley/ggplot2/wiki/labeller I tried to make a long name like this Light and heavy good vehicles (diesel) -\nGVX f2 = facet_grid(vehicle ~ ., labeller=label_wrap_gen(width=15)) eventually, I got something

Re: [R] ggplot rank stack bar automatically.

2012-02-21 Thread vd3000
Hi Ista, I got it. I try to deselect the all packages and try to run the code again. Eventually, the console display no "digest" package. You are so nice. A lot of things to learn... Many thanks. Best, VD -- View this message in context: http://r.789695.n4.nabble.com/ggplot-rank-stack-bar-autom

Re: [R] ggplot rank stack bar automatically.

2012-02-20 Thread vd3000
> df <- structure(c(106487, 495681, 1597442, 2452577, 2065141, 2271925, 4735484, 3555352, 8056040, 4321887, 2463194, 347566, 621147, 1325727, 1123492, 800368, 761550, 1359737, 1073726, 36, 53, 141, 41538, 64759, 124160, 69942, 74862, 323543, 247236, 112059, 16595, 3702

Re: [R] ggplot rank stack bar automatically.

2012-02-18 Thread vd3000
Hi, Ista, I found the graph were same as "before recording" http://izahn.homedns.org/tmp/barplotOriginal.png Anyway, I will try again, Many thanks. I am now trying to stack it horizontally and found that the axis text overlap each other!! New battle start again. X_X!! VD. -- View this messag

Re: [R] ggplot rank stack bar automatically.

2012-02-18 Thread vd3000
Hi, Ista, 1. /"df.m <- transform(df.m, Period = reorder(Period, -1*value)) ggplot(df.m, aes(x = Period, y = value/1e+06, fill = Region)) + geom_bar(stat = "identity", position = "stack") "/ I have followed your instruction but I found the sequence did not change. 2. I am looking for the st

Re: [R] ggplot rank stack bar automatically.

2012-02-16 Thread vd3000
Hi, Micheal, Are you talking about the recode for eliminating "\" problem? I think I am looking for how to eliminate it when I import the data file... THAnks. VD. -- View this message in context: http://r.789695.n4.nabble.com/ggplot-rank-stack-bar-automatically-tp4391042p4393328.html Sent from

[R] ggplot rank stack bar automatically.

2012-02-15 Thread vd3000
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

[R] How to solve long tick labels (axis.text.x)

2012-02-11 Thread vd3000
Hi, all, I am a newbie for [r]. I am currently trying to learn this example. /http://learnr.wordpress.com/2009/03/17/ggplot2-barplots// /http://learnr.wordpress.com/2009/03/17/ggplot2-barplots/ / After I made a drawing /c <- b + facet_grid(Region ~ .) + opts(legend.position = "none") / If

Re: [R] ggplot theme_update

2012-02-03 Thread vd3000
Hi, David, Thanks a lot. I don't know how it works after adding the line after library(ggplot2) /base_theme <- theme_update(axis.text.x = theme_text(angle = 0, hjust = 0.5), axis.text.y = theme_text(angle = 0, hjust = 0.5), panel.grid.major = theme_line(colour = "grey90"), panel.grid.minor = th

[R] ggplot theme_update

2012-02-03 Thread vd3000
Hi, all, I am a newbie for [r]. I am currently trying to learn this example. http://learnr.wordpress.com/2009/03/17/ggplot2-barplots/ http://learnr.wordpress.com/2009/03/17/ggplot2-barplots/ I know if I need to show the graph properly, I need to update the theme by this command: *> immigrati