Skip to content

qcut returning confusing first bin with all positive integer series #1469

Closed
@gerigk

Description

@gerigk

bins[0] -= 0.001 * (x.max() - x.min())
should probably be tuned - especially for integers
maybe related to issue #1462

qcut(Series([0,1,2,3,4,5,3531132324355]))

Factor:
array([(-3531132324.355, 1.5], (-3531132324.355, 1.5], (1.5, 3], (1.5, 3],
(3, 4.5], (4.5, 3531132324355], (4.5, 3531132324355]], dtype=object)
Levels (4): array([(-3531132324.355, 1.5], (1.5, 3], (3, 4.5], (4.5, 3531132324355]], dtype=object)

qcut(Series([0,1,2,3,4,5,3535))

Factor:
array([(-3.535, 1.5], (-3.535, 1.5], (1.5, 3], (1.5, 3], (3, 4.5],
(4.5, 3535], (4.5, 3535]], dtype=object)
Levels (4): array([(-3.535, 1.5], (1.5, 3], (3, 4.5], (4.5, 3535]], dtype=object)

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions