Skip to content

pivot_table() to groupby().agg() #9

Open
@baziotis

Description

@baziotis

Instance of the original version

# Example:
df.pivot_table(index='Survived', values='Age', aggfunc='sum')

Instance of the faster version

# Example:
df.groupby('Survived').agg({'Age': 'sum'})

This is about 3x faster on the titanic dataset. We need to test more.

Metadata

Metadata

Assignees

No one assigned

    Labels

    patternA pattern that Dias does not already rewrite into a faster version.

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions