Data Science Jumpstart with 10 Projects Transcripts
Chapter: Project 6: Working with Time Series - Air Quality over Time
Lecture: Converting Dates to UTC in Pandas

Login or purchase this course to watch this video and the rest of the course contents.
0:00 In this section, we're going to look at our time a little bit more and figure out where that time is.
0:07 So here's our cleaned up data. If you look at it, it says it's a date time 64NS.
0:11 I'm going to stick that into UTC time. And when I do that, you can see that this says UTC down here.
0:18 Alternatively, I could convert this to a PyArrow timestamp. Turns out that using PD to date time
0:25 doesn't give us PyArrow. It actually gives us a NumPy date time. So if we wanted to be pedantic
0:32 about using a PyArrow time, we could. That also supports TZ localize. If you want to pull up the
0:38 documentation for this, you can come up here and hit shift tab a few times. And this says you have
0:45 a naive date time and you want to make it time zone aware. To be pedantic, UTC is not a time zone, but this is how we convert to UTC time.


Talk Python's Mastodon Michael Kennedy's Mastodon