-
-
Notifications
You must be signed in to change notification settings - Fork 168
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
Percentile Calculation Bug? #80
Comments
i think it's fixed here |
the fix has not been released yet @montanaflynn |
I think this is just a case of two different percentile algorithm's. Do you have a reference to the percentile algo that produces 1.5? The output should be 2 according to numpy and wolframalpha: import numpy as np
a = np.array([1, 2, 3])
print(np.percentile(a, 50))
// 2 https://www.wolframalpha.com/input?i=50th+percentile+of+1%2C+2%2C+3 |
yes i believe for {0, 300, 600}, it should be 300, and for {1, 2, 3}, it should be 2. @montanaflynn is the fix (along with all the other merged pull requests), ready to be released yet? |
Given a slice
a := []float64{0, 300, 600}
stats.Percentile(a, 50)
should return 300. However it returns 150.The text was updated successfully, but these errors were encountered: