Skip to content

TST: add additional test cases for pivot_table with categorical data #21370

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

Closed
jorisvandenbossche opened this issue Jun 7, 2018 · 2 comments · Fixed by #28803
Closed

TST: add additional test cases for pivot_table with categorical data #21370

jorisvandenbossche opened this issue Jun 7, 2018 · 2 comments · Fixed by #28803
Labels
good first issue Testing pandas testing functions or related to the test suite
Milestone

Comments

@jorisvandenbossche
Copy link
Member

xref #21252 (comment)

Add additional test cases for:

Using the same definition of df as you used in your test, columns/values is incorrect:

In [3]: pd.__version__
Out[3]: '0.23.0'

In [4]: df.pivot_table(columns='A', values='B')
Out[4]:
A  NaN  low
B  2.0  3.0

Similarly index/columns/values is incorrect:

In [5]: df['AA'] = df['A']

In [6]: df.pivot_table(index='A', columns='AA', values='B')
Out[6]:
AA   NaN  low
A
NaN  2.0  NaN
low  NaN  3.0
@uds5501
Copy link
Contributor

uds5501 commented Jun 8, 2018

@jorisvandenbossche if this issue is still open, I would like to take this one up!

@gfyoung
Copy link
Member

gfyoung commented Jun 8, 2018

@uds5501 : This is definitely still fair game. Go for it!

uds5501 added a commit to uds5501/pandas that referenced this issue Jun 8, 2018
TST: add additional test cases for pivot_table with categorical data pandas-dev#21370
@jreback jreback modified the milestones: 0.24.0, 0.25.0 Oct 23, 2018
@jreback jreback modified the milestones: 0.25.0, 1.0 May 12, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
good first issue Testing pandas testing functions or related to the test suite
Projects
None yet
4 participants