Skip to content

Instantly share code, notes, and snippets.

@VioletVivirand
Created April 25, 2017 00:32
Show Gist options
  • Save VioletVivirand/7a28d58350691c7d0a52f7b05d05f21a to your computer and use it in GitHub Desktop.
Save VioletVivirand/7a28d58350691c7d0a52f7b05d05f21a to your computer and use it in GitHub Desktop.
Parse from String Series to Timestamp (unit: ms)
# 把 s 代換成 DataFrame 中的時間欄位
s.apply(lambda x: int(datetime.datetime.strptime(x,"%Y-%m-%d %H:%M:%S").strftime('%s'))*1000)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment