It is not clear what curve you want to plot, but this code may help get you
started (the final plot will probably need the x and y limits expanded and
maybe other options changed):
x <- rnorm(100, rep( c(100,105), c(75,25)), 2 )
hist(x, probability=TRUE)
lines( density(x), col='green' )
curve(
leo_wa wrote:
i want to plot the histogram and the curve in the same graph.if i have a set
of data ,i plot the histogram and also want to see what distribution it
was.So i want to plot the curve to know what distribution it like.
To draw the curve and the distribution you should have an ide
leo_wa hotmail.com> writes:
>
>
> i want to plot the histogram and the curve in the same graph.if i have a set
> of data ,i plot the histogram and also want to see what distribution it
> was.So i want to plot the curve to know what distribution it like.
You will find below an example using on
leo_wa hotmail.com> writes:
>
> i want to plot the histogram and the curve in the same graph.if i have a
> set of data ,i plot the histogram and also want to see what distribution
> it was.So i want to plot the curve to know what distribution it like.
See the example under histogram/lattice
4 matches
Mail list logo