Skip to content

Example in Chapter 9 Aggregate Methods use NumPy backend without informing the reader. #35

@sjgtheunissen

Description

@sjgtheunissen

In 9.2 there is an example to calculate the percentage of cars with mileage greater than 20. Both these examples use NumPy backend, while the data was loaded in, in Chapter 7 using PyArrow backend (and in the erata using NumPy backend).

city_mpg.gt(20).sum() works correctly
city_mpg.gt(20).mul(100).mean() does not work with PyArrow backend TypeError: operation 'mul' not supported for dtype 'bool[pyarrow]' with object of type <class 'int'>

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions