将gmt转换为 pandas 当地时区 [英] convert gmt to local timezone in pandas

查看:73
本文介绍了将gmt转换为 pandas 当地时区的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我有一个格林尼治标准时间时间戳,我需要将其转换为本地时区(考虑到夏时制).

I have a gmt timestamp and I need to convert it into a local timezone (taking into account daylight saving).

您知道如何在熊猫中做到这一点吗?谢谢!

do you know how to do that in pandas? thanks!

推荐答案

tz_localize 是可能的候选人.

http://pandas.pydata.org/pandas-docs/version/0.17.1/generation/pandas.Series.tz_localize.html

这篇关于将gmt转换为 pandas 当地时区的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆