On Apr 23, 2011, at 2:10 PM, kv wrote:
> Hello,
>
> i'm using <R.h> & <Rmath.h>.
> What is the c equivalent to sort(x,deceasing=T)
>
> i.e. to get sort(x) i type R_qsort(x, 1, n), where
> do i set the decreasing=T flag ?
>
> More generally, is there a place where the
> functions in the R sources are documented ?
methods(sort)
sort.default # leads to
sort.int
So, if you look at the R code it appears that decreasing-requests are
handled by first reversing the argument order before calling
the .Internal code. Sometimes the code is documented in the R source.
--
David Winsemius, MD
West Hartford, CT