Notice: This page requires JavaScript to function properly.
Please enable JavaScript in your browser settings or update your browser.
Challenge: Average Metrics Across Taxi Types | Working with Dates and Times in pandas
Dealing with Dates and Times in Python
course content

Course Content

Dealing with Dates and Times in Python

Dealing with Dates and Times in Python

1. Working with Dates
2. Working with Times
3. Timezones and Daylight Savings Time (DST)
4. Working with Dates and Times in pandas

bookChallenge: Average Metrics Across Taxi Types

Great! As for now, we have our dataset cleared from abnormally long rides and rides with ending time preceded starting. As we investigated, it happened because of misusage of 12 and 24-hour formats.

Let's try to find out some interesting insights from this dataset.

Task

  1. Apply .total_seconds() function to duration column using map and lambda functions.
  2. Group observations by taxi type (vendor_id column). Then, choose columns dist_meters, duration, and calculate mean. Then apply function avg_m to dist_meters and avg_dur to duration. The functions are defined in the code.

Switch to desktopSwitch to desktop for real-world practiceContinue from where you are using one of the options below
Everything was clear?

How can we improve it?

Thanks for your feedback!

Section 4. Chapter 8
toggle bottom row

bookChallenge: Average Metrics Across Taxi Types

Great! As for now, we have our dataset cleared from abnormally long rides and rides with ending time preceded starting. As we investigated, it happened because of misusage of 12 and 24-hour formats.

Let's try to find out some interesting insights from this dataset.

Task

  1. Apply .total_seconds() function to duration column using map and lambda functions.
  2. Group observations by taxi type (vendor_id column). Then, choose columns dist_meters, duration, and calculate mean. Then apply function avg_m to dist_meters and avg_dur to duration. The functions are defined in the code.

Switch to desktopSwitch to desktop for real-world practiceContinue from where you are using one of the options below
Everything was clear?

How can we improve it?

Thanks for your feedback!

Section 4. Chapter 8
toggle bottom row

bookChallenge: Average Metrics Across Taxi Types

Great! As for now, we have our dataset cleared from abnormally long rides and rides with ending time preceded starting. As we investigated, it happened because of misusage of 12 and 24-hour formats.

Let's try to find out some interesting insights from this dataset.

Task

  1. Apply .total_seconds() function to duration column using map and lambda functions.
  2. Group observations by taxi type (vendor_id column). Then, choose columns dist_meters, duration, and calculate mean. Then apply function avg_m to dist_meters and avg_dur to duration. The functions are defined in the code.

Switch to desktopSwitch to desktop for real-world practiceContinue from where you are using one of the options below
Everything was clear?

How can we improve it?

Thanks for your feedback!

Great! As for now, we have our dataset cleared from abnormally long rides and rides with ending time preceded starting. As we investigated, it happened because of misusage of 12 and 24-hour formats.

Let's try to find out some interesting insights from this dataset.

Task

  1. Apply .total_seconds() function to duration column using map and lambda functions.
  2. Group observations by taxi type (vendor_id column). Then, choose columns dist_meters, duration, and calculate mean. Then apply function avg_m to dist_meters and avg_dur to duration. The functions are defined in the code.

Switch to desktopSwitch to desktop for real-world practiceContinue from where you are using one of the options below
Section 4. Chapter 8
Switch to desktopSwitch to desktop for real-world practiceContinue from where you are using one of the options below
some-alt