Thanks, 'cut()' was indeed what I was looking for
thanks
2009/7/16 :
> Hi: I'm not sure if I understand what you want but below might help you ?
> see cut for more details by doing ?cut.
>
>
> probs<-c(0.001,0.5,0.02,.05,0.12,0.23,0.5,0.6,0.59,0.7)
> probs
>
> temp <- cut(probs,breaks=seq(0,1,le
Dear torpedo,
Take a lookat ?cut and its examples.
HTH,
Jorge
On Wed, Jul 15, 2009 at 11:26 PM, torpedo fisken wrote:
> I got a vector of probabilities like,
> probs<-c(0.001,0.5,0.02,1,.)
>
> Is there any nice and easy builtin function to get the number of
> occurences within some specifi
I got a vector of probabilities like,
probs<-c(0.001,0.5,0.02,1,.)
Is there any nice and easy builtin function to get the number of
occurences within some specified probabality range.
Like with 2% it would be
occur[1] = sum(probs[probs>0&probs<0.02])
occur[2] = sum(probs[probs>0.02&probs<0.04
3 matches
Mail list logo