Re: [R] histogram-like plot with two variables

2008-09-29 Thread Greg Snow
] 801.408.8111 > -Original Message- > From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] > project.org] On Behalf Of Philipp Pagel > Sent: Monday, September 29, 2008 5:40 AM > To: r-help@r-project.org > Subject: Re: [R] histogram-like plot with two variables > > On Mo

Re: [R] histogram-like plot with two variables

2008-09-29 Thread Philipp Pagel
On Mon, Sep 29, 2008 at 04:02:05AM +0200, Jörg Groß wrote: > Hi, > > I want to plot a binomial propability distribution. > > I know how to generate the data; > >x <- seq(from=0, to=14, by=1) >y <- dbinom(x, 14, 0.7, log = FALSE) > > I tried: > plot(x,y, type="h") > but the bars are ve

Re: [R] histogram-like plot with two variables

2008-09-29 Thread Jim Lemon
Jörg Groß wrote: Hi, I want to plot a binomial propability distribution. I know how to generate the data; x <- seq(from=0, to=14, by=1) y <- dbinom(x, 14, 0.7, log = FALSE) but what I don't know is how to plot this within a histogram like plot. Because the histogram function only accept

Re: [R] histogram-like plot with two variables

2008-09-29 Thread Duncan Murdoch
On 28/09/2008 10:02 PM, Jörg Groß wrote: Hi, I want to plot a binomial propability distribution. I know how to generate the data; x <- seq(from=0, to=14, by=1) y <- dbinom(x, 14, 0.7, log = FALSE) but what I don't know is how to plot this within a histogram like plot. Because the histog

Re: [R] histogram-like plot with two variables

2008-09-28 Thread jim holtman
Try: plot(x,y,type='s') lines(x,y, type='h') On Sun, Sep 28, 2008 at 10:02 PM, Jörg Groß <[EMAIL PROTECTED]> wrote: > Hi, > > I want to plot a binomial propability distribution. > > I know how to generate the data; > > x <- seq(from=0, to=14, by=1) > y <- dbinom(x, 14, 0.7, log = FALSE) > > b