I'm trying to add a normal distribution curve to a histogram using curve
.
This is my code:
hist(df$col, freq=T)
curve( dnorm(x, mean=8.9,sd=5), 0, 30, add=T, col="blue")
The histogram does look fine, but the curve is not adequately displayed (just a blue line on the x axis)
I can't figure out what I'm doing wrong. would greatly appreciate your help!