[R] factors levels ?

Eik Vettorazzi E.Vettorazzi at uke.uni-hamburg.de
Tue Nov 13 14:38:06 CET 2007


cut(X,Y,right=F)

W Eryk Wolski schrieb:
> Hi,
>
> It's just some example code.. The application is uninteresting. I am
> searching for some functionality.
>
> X <- rnorm(100) //my data
>
> Y <- seq(-3,3,by=0.1) // bin boundaries.
>
> Now I would like to generate a - list of factors,  length as X...
> i.e.: all values in the range [-3,-2.9) have the same factor... [-3,-2.9) etc.
>
> I would assume R has such a function but I cant recall which one it is.
>
>
>   

-- 
Eik Vettorazzi
Institut für Medizinische Biometrie und Epidemiologie
Universitätsklinikum Hamburg-Eppendorf

Martinistr. 52
20246 Hamburg

T ++49/40/42803-8243
F ++49/40/42803-7790



More information about the R-help mailing list