Re: [R] problems hist() and density

2009-07-27 Thread Jan Teichmann
Thank you. I'm sorry for my question. Sure, I've to integrate a density function to get the probabilities... I didn't noticed the small breaks and that's why I was confused. I expected a histogram with probabilities for the realizations. Am Sonntag, den 26.07.2009, 14:27 -0400 schrieb jim holtman:

Re: [R] problems hist() and density

2009-07-26 Thread jim holtman
"sums to one" I should have said. On Sun, Jul 26, 2009 at 7:43 AM, Jan Teichmann wrote: > Hello, > > I have a problem with the hist() function and showing densities. The > densities sum to 50 and not to 1! I use R version 2.9.1 (2009-06-26) and > I load the seqinR library. > > My data is the foll

Re: [R] problems hist() and density

2009-07-26 Thread jim holtman
It is the 'area' under the curve that sums to zero. Look at what the difference is between the 'breaks' (0.02). multiply this by 50 and you get 1. On Sun, Jul 26, 2009 at 7:43 AM, Jan Teichmann wrote: > Hello, > > I have a problem with the hist() function and showing densities. The > densities s

[R] problems hist() and density

2009-07-26 Thread Jan Teichmann
Hello, I have a problem with the hist() function and showing densities. The densities sum to 50 and not to 1! I use R version 2.9.1 (2009-06-26) and I load the seqinR library. My data is the following vector: [1] 0.140 0.200 0.220 0.2828283 0.160 0.160 0.360 [8] 0.160