Skip to content

shouldn't mangle_dupe_cols add an underscore rather than a dot in read_csv? #8908

Closed
@mbakker7

Description

@mbakker7

When I use read_csv to read a file which has columns with the same name, the names are amended with .1, .2, etc, when mangle_dupe_cols=True in read_csv.

Wouldn't it make more sense to amend them as _1, _2, etc., so that columns of a dataframe can still be accessed with the dot syntax: df.name_1 works fine, but df.name.1 doesn't work.

Just a suggestion,

Mark

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions