I tried that, but for some reason the scale is wrong? So the density doesn't
show up on the histogram. Also, I'd prefer not to use the density because I
don't want the line plot to begin at a value of 0. I'm trying to emulate an
exponential decay.
Thanks for the help.
-Original
Okay I've included a picture of the plot I've been getting with the commands:
hist(data,freq=F)
lines(Y~X)
Basically I want the line circled in red to overlap the histogram because that
line is supposed to represent the exponential decay nature of the histogram.
Thanks!
-Original
Hello,
I'm trying to superimpose a line plot onto a histogram but I'm not having
any luck. I've attached the dataset. What I did was:
hist(data,freq=F)
Now I'm trying to superimpose the following points with a line connecting
them onto the histogram:
xy
100 0.535665393824959
200
How about the answer by Demitris?
Regards a lot,
miltinho
From: Dimitris Rizopoulos [EMAIL PROTECTED]
Date: Jun 16, 2008 4:05 AM
Subject: Re: [R] Superimposing Line over Histogram in Density Plot
To: Gundala Viswanath [EMAIL PROTECTED]
Cc: [EMAIL PROTECTED]
try something like this:
x -
Thanks for the quick response. But the points I'm trying to superimpose
isn't exactly the density of the data. Is there any other way to do it?
From: milton ruser [mailto:[EMAIL PROTECTED]
Sent: July 5, 2008 6:56 AM
To: Edwin Lei
Cc: r-help@r-project.org
Subject: Re: [R] trying to superimpose
5 matches
Mail list logo