diff --git a/MD5 b/MD5 index 918d337..4c05112 100644 --- a/MD5 +++ b/MD5 @@ -9,7 +9,7 @@ d143e1321d840bb810d9648e54e22c9c *man/fpos.Rd 1cce4277e2dd16a0f68c96d744b7bc17 *man/funique.Rd 3e0b7c90f2f4a9c4be404cbc6ac69b16 *man/iif.Rd 578fe4903cc4f5d7bc5a6f346be1e9e9 *man/nif.Rd -f743be513a551d48d04f0a5f31c5f27d *man/psort.Rd +ef4ce6330a0f6a2ec63ccfd365729963 *man/psort.Rd d4d3e5eb9266703d533ef42053474ac6 *man/psum.Rd 14e3add07190fd18d0161f4f0b0b5257 *man/setlevels.Rd e0d3b091b5182fdcc8868c93a2c59476 *man/topn.Rd diff --git a/man/psort.Rd b/man/psort.Rd index b4b4133..1c11b4f 100644 --- a/man/psort.Rd +++ b/man/psort.Rd @@ -25,4 +25,18 @@ x = c("b","A","B","a","\xe4") Encoding(x) = "latin1" identical(psort(x, c.locale=FALSE), sort(x)) identical(psort(x, c.locale=TRUE), sort(x, method="radix")) + +# Benchmarks +# ---------- +# strings = as.character(as.hexmode(1:1000)) +# x = sample(strings, 1e8, replace=TRUE) +# system.time({kit::psort(x, na.last = TRUE, nThread = 1L)}) +# user system elapsed +# 2.833 0.434 3.277 +# system.time({sort(x,method="radix",na.last = TRUE)}) +# user system elapsed +# 5.597 0.559 6.176 +# system.time({x[order(x,method="radix",na.last = TRUE)]}) +# user system elapsed +# 5.561 0.563 6.143 }