A RetroSearch Logo

Home - News ( United States | United Kingdom | Italy | Germany ) - Football scores

Search Query:

Showing content from https://pandas.pydata.org/docs/dev/development/../reference/api/pandas.Index.infer_objects.html below:

pandas.Index.infer_objects — pandas 3.0.0.dev0+2231.g4f2aa4d2be documentation

pandas.Index.infer_objects#
final Index.infer_objects(copy=True)[source]#

If we have an object dtype, try to infer a non-object dtype.

Parameters:
copybool, default True

Whether to make a copy in cases where no inference occurs.

Returns:
Index

An Index with a new dtype if the dtype was inferred or a shallow copy if the dtype could not be inferred.

Examples

>>> pd.Index(["a", 1]).infer_objects()
Index(['a', '1'], dtype='object')
>>> pd.Index([1, 2], dtype="object").infer_objects()
Index([1, 2], dtype='int64')

RetroSearch is an open source project built by @garambo | Open a GitHub Issue

Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo

HTML: 3.2 | Encoding: UTF-8 | Version: 0.7.4