[R] inverse function of order()
Liaw, Andy
andy_liaw at merck.com
Mon Oct 4 16:50:53 CEST 2004
r[order(o)] seems to work alright...
Andy
> From: Wolfram Fischer
>
> I have:
>
> d <- sample(10:100, 9)
> o <- order(d)
> r <- d[o]
>
> How I can get d (in the original order), knowing only r and o?
>
> Thanks - Wolfram
>
> ______________________________________________
> R-help at stat.math.ethz.ch mailing list
> https://stat.ethz.ch/mailman/listinfo/r-help
> PLEASE do read the posting guide!
> http://www.R-project.org/posting-guide.html
>
>
More information about the R-help
mailing list