Movatterモバイル変換


[0]ホーム

URL:


Skip to main content
Ctrl+K

pandas.Timestamp.to_pydatetime#

Timestamp.to_pydatetime(warn=True)#

Convert a Timestamp object to a native Python datetime object.

If warn=True, issue a warning if nanoseconds is nonzero.

Examples

>>>ts=pd.Timestamp('2020-03-14T15:32:52.192548')>>>ts.to_pydatetime()datetime.datetime(2020, 3, 14, 15, 32, 52, 192548)

Analogous forpd.NaT:

>>>pd.NaT.to_pydatetime()NaT

[8]ページ先頭

©2009-2025 Movatter.jp