-
Notifications
You must be signed in to change notification settings - Fork 41
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
quantile is inefficient in common case of CI calculation #84
Comments
Why is that the case? I understand why there's no performance gain, but I wouldn't have expected it to be slower. |
The reason is here https://github.com/JuliaLang/Statistics.jl/blob/54f9b0d999813aa9fab039f632df222ffd2a96a8/src/Statistics.jl#L972 for one value |
Wow, OK. We should probably just call |
Yes, but only of 2 quantiles. Probably for more than 2 quantiles it is better to do what we do now I think. |
Example:
but
The reason is that doing partial sort twice on tails if we are near the end is faster than doing one partial sort. Unfortunately this is a common case I would assume. Maybe we should introduce some optimization here?
The text was updated successfully, but these errors were encountered: