Skip to content

DOC: Remove Series.view(dtype=None) always trying float64 #20281

Closed as not planned
@jorisvandenbossche

Description

@jorisvandenbossche

xref https://github.com/pandas-dev/pandas/pull/20220/files#r173655704

Currently, Series.view() is actually equivalent to Series.view('float64') (because that is the default dtype in the Series constructor) which often does not make sense. Not too important (as there are not many reasons to use this function in pandas), but I think we should fix to either a) disallow dtype=None or either b) if dtype is None to set dtype = self.dtype (behaviour of numpy if no dtype is specified)

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