Skip to content
Prev 280813 / 398503 Next

data vector to corresonding percentile ranks

On Dec 23, 2011, at 10:28 AM, Steve Jones wrote:

            
Unsuccessful? How? Seems like a reasonable strategy:

set.seed(123)
  x <- rnorm(1000)
xCdist <- ecdf(x)

Seems to give sensible results.

 > x[1]
[1] -0.7104066
 > 100*xCdist(x[1])
[1] 23.4

 > x[2]
[1] 0.2568837
 > 100*xCdist(x[2])
[1] 60
My advice would be to post what code you were trying so that you can  
get help understand what difficulties you need to overcome.