Re: [R] ggplot2 histograms

2010-12-13 Thread Hadley Wickham
t; [had...@rice.edu] > Sent: 01 December 2010 14:27 > To: Small Sandy (NHS Greater Glasgow & Clyde) > Cc: ONKELINX, Thierry; r-help@r-project.org > Subject: Re: [R] ggplot2 histograms > >> However if you do: >> ggplot(data=dafr, aes(x = d1, fill=d2)) + geom_histogram(binwidth

Re: [R] ggplot2 histograms

2010-12-01 Thread Small Sandy (NHS Greater Glasgow & Clyde)
@rice.edu] Sent: 01 December 2010 14:27 To: Small Sandy (NHS Greater Glasgow & Clyde) Cc: ONKELINX, Thierry; r-help@r-project.org Subject: Re: [R] ggplot2 histograms > However if you do: > ggplot(data=dafr, aes(x = d1, fill=d2)) + geom_histogram(binwidth = 1, > position = positio

Re: [R] ggplot2 histograms

2010-12-01 Thread Hadley Wickham
> However if you do: > ggplot(data=dafr, aes(x = d1, fill=d2)) + geom_histogram(binwidth = 1, > position = position_dodge(width=0.99)) > > The position of first bin which goes from 0-2 appears to start at about 0.2 > (I accept that there is some "white space" to the left of this) while the > pos

Re: [R] ggplot2 histograms

2010-12-01 Thread Ista Zahn
ll > Clinical Physicist > NHS Forth Valley > (Tel: 01324567002) > and > NHS Greater Glasgow and Clyde > (Tel: 01412114592) > > From: ONKELINX, Thierry [thierry.onkel...@inbo.be] > Sent: 30 November 2010 14:57 > To: Small Sandy (NHS Greater Glasgow & Clyde); r-help@

Re: [R] ggplot2 histograms

2010-12-01 Thread Small Sandy (NHS Greater Glasgow & Clyde)
ember 2010 14:57 To: Small Sandy (NHS Greater Glasgow & Clyde); r-help@r-project.org Subject: RE: [R] ggplot2 histograms Dear Sandy, Have a look at the position argument of geom_histogram. ggplot(data=dafr, aes(x = d1, fill=d2)) + geom_histogram(binwidth = 1, position = position_dodge()) gg

Re: [R] ggplot2 histograms

2010-11-30 Thread Hadley Wickham
You may find it easier to use a frequency polygon, geom = "freqpoly". Hadley On Tue, Nov 30, 2010 at 2:36 PM, Small Sandy (NHS Greater Glasgow & Clyde) wrote: > Hi > > With ggplot2 I can very easily create beautiful histograms but I would like > to put two histograms on the same plot. The histo

Re: [R] ggplot2 histograms

2010-11-30 Thread ONKELINX, Thierry
Dear Sandy, Have a look at the position argument of geom_histogram. ggplot(data=dafr, aes(x = d1, fill=d2)) + geom_histogram(binwidth = 1, position = position_dodge()) ggplot(data=dafr, aes(x = d1, fill=d2)) + geom_histogram(binwidth = 1, position = position_dodge(width = 0.5), alpha = 0.5) Best

Re: [R] ggplot2 histograms... a subtle error found

2010-08-09 Thread hadley wickham
> When ggplot2 verifies the widths before stacking (the default position for > histograms), it computes the widths from the minimum and maximum values for > each bin.  However, because the width of the bins (0.28) is much smaller > than the scale of the edges (6.8e+09), there is some underflow and

Re: [R] ggplot2 histograms... a subtle error found

2010-08-02 Thread Xu Wang
There is a google group dedicated to ggplot2. It might be worth making a post there: http://groups.google.com/group/ggplot2?pli=1 -- View this message in context: http://r.789695.n4.nabble.com/ggplot2-histograms-a-subtle-error-found-tp2305814p2311082.html Sent from the R help mailing list archi

Re: [R] ggplot2 histograms... a subtle error found

2010-08-02 Thread Brian Diggs
On 7/28/2010 5:04 PM, Mike Williamson wrote: Hello all, I have a peculiar and particular bug that I stumbled across with ggplot2. I cannot seem to replicate it with anything other than my specific data set. Here is the problem: - when I try to plot a histogram, allowing for ggpl