https://github.com/cran/quantreg
Revision 029a6bd97dd27d89db125da22a3b5a4b585cd97f authored by Roger Koenker on 22 March 2012, 00:00:00 UTC, committed by Gabor Csardi on 22 March 2012, 00:00:00 UTC
1 parent f8a9a26
Raw File
Tip revision: 029a6bd97dd27d89db125da22a3b5a4b585cd97f authored by Roger Koenker on 22 March 2012, 00:00:00 UTC
version 4.78
Tip revision: 029a6bd
kuantile.r
# Wrapper to compute several quantiles of a sample of n observations
# Calls  K.C. Kiwiel's version of Floyd and Rivest's select algorithm
# Caveat Emptor!!  The ks need to  be sorted.
subroutine kuantile(k,m,n,x)
integer i,j,k(m),m,n
double precision  x(n)

j = 0
do i = 1,m{
	call dsel05(k(i)-j,n-j,x(j+1))
	j = k(i)
	}
return
end
back to top