-
Notifications
You must be signed in to change notification settings - Fork 18
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
Decile calculation with "ntile"... #161
Comments
Hi, could you show the versions of datar: from datar import get_versions
get_versions() |
Hi, >>> from datar import get_versions
>>> get_versions()
python : 3.10.4 (main, Mar 31 2022, 08:41:55) [GCC 7.5.0]
datar : 0.10.2
simplug : 0.2.1
executing : 1.2.0
pipda : 0.10.0
datar-numpy : 0.0.0
numpy : 1.23.4
datar-pandas: 0.0.0
pandas : 1.5.2 Thanks! |
This is a nice catch! Try updating pip install -U datar[pandas] and also try |
By the way, thanks for the compliments:
Do you mind if I put it as a testimonial in the README file? |
Thanks a lot for your quick fix!. No, I do not mind at all. |
Thanks! Please confirm if this is fixed and feel free to close it if so. |
Thanks, Yes, I have just updated decil n
<category> <int64>
0 1 1438
1 2 1437
2 3 1437
3 4 1437
4 5 1437
5 6 1439
6 7 1435
7 8 1585
8 9 1293
9 10 1434 Thanks again, |
Hi,
Thanks for your excellent package to port R (dplyr) flow of processing to Python. I have been using another alternatives, and yours is the one that offers the most extensive and equivalent to what is possible now with dplyr.
I have an issue with how
ntile()
calculates the different groups for a vector of probabilities ("p2").This is the output of that calculation.
But when you calculates how many values are in each bucket, it shows something strange:
The groups are very dissimilar.
For the sake of reproducibility, In this file you can find that dataframe with the probabilities and the calculated decile.
Now, I am calculating the right decile with pandas
qcut()
method, which offers the right output, with a much mofre balanced number of elements in each bucket.Thanks again,
Carlos.
The text was updated successfully, but these errors were encountered: