Skip to content

Commit

Permalink
Merge pull request #17 from sophiewagner7:sophie
Browse files Browse the repository at this point in the history
edit 2_taxi plot desc
  • Loading branch information
sophiewagner7 authored Dec 13, 2024
2 parents bfd8e7f + 3a88932 commit 9867036
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 6 deletions.
8 changes: 4 additions & 4 deletions sections/3/2_taxi_usage_patterns.qmd
Original file line number Diff line number Diff line change
Expand Up @@ -72,7 +72,7 @@ df |>
theme(legend.position = "bottom")
```

Rider behavior does seem to be influenced by time of day. From the plot above we can see that longer trups are more common during the late-night and early-morning hours. Perhaps this indicates that people travel greater distances for late-night activities. The distribution of trip distances appears to stabilize between 7am and 7pm, with higher proportion of shorter-distance trips compared to long. Interestingly, time of day was the only time-measure that seemed to impact this aspect of rider behavior: day of the week and month do not appear to have any influence on trip distance. This information isn't totally revolutionary, though it may underscore the importance of focusing on particular hours to account for variability in trip length or usage patterns.
From the plot above we can see that longer trips are more common during the late-night and early-morning hours. Perhaps this indicates that people travel greater distances for late-night activities. The distribution of trip distances appears to stabilize between 7am and 7pm, with higher proportion of shorter-distance trips compared to long. Interestingly, time of day was the only time-measure that seemed to impact this aspect of rider behavior: day of the week and month do not appear to have any influence on trip distance. This information isn't totally revolutionary, though it may underscore the importance of focusing on particular hours to account for variability in trip length or usage patterns.

With respect to trip volume, there is a significant variation by time of day as anticipated. When plotting all dates, we noticed some clustering in trip counts by hour, and were able to decipher that this behavior is largely related to the day of the week.

Expand Down Expand Up @@ -104,9 +104,9 @@ temp_df |>
scale_x_continuous(breaks = seq(0, 23, by = 3)) +
scale_y_continuous(labels=thousands) +
labs(
title = "Trip Counts by Hour with Day of Week Labels",
title = "Average Hourly Trips by Day of the Week",
x = "Hour of the Day",
y = "Average Trip Count",
y = "Average Number of Trips",
color = "Day Type"
) +
theme_minimal() +
Expand Down Expand Up @@ -182,7 +182,7 @@ df |>
theme(legend.position="bottom")
```

Even within the weekday rush hour subset, ridership varies. We see that Mondays have the lowest median trip counts and the most compact IQR, which could be related to Monday as a common WFH day (explaining lower average) and people tend to be consistent in their behavior at the start of the week (less variability). Tuesday through Thursday, we see a pretty consistent median and variabilty. Friday, we see the highest variability, likely because people engage in social activities after work. Tuesday through Thursday show relatively consistent median trip counts and narrower distributions, reflecting more regular commuting patterns. There are some outliers visible on the plot worth investigating, perhaps relating to around-holiday times, special events, or weather conditions.
Even within the weekday rush hour subset, ridership varies. Mondays and Fridays have the lowest median trip counts in the morning rush hour, which could be related to both days as a common WFH day. Tuesday through Thursday, we see a pretty consistent median and variability in the morning rush hour. However, we see an upward trend in the median number of evening rush hour trips, peaking at Friday, which also has the highest variability. This upward trend reflects people's proclivity to engaging in social activities later in the week, whereas earlier in the week they might be on the straight and narrow.

```{r}
df |>
Expand Down
4 changes: 2 additions & 2 deletions sections/3/4_weather_vs_trips.qmd
Original file line number Diff line number Diff line change
Expand Up @@ -102,12 +102,12 @@ pivot_trip_distance_df |>
# geom_errorbar(aes(ymin = avg_trips - se, ymax = avg_trips + se),
# width = 0.2, position = position_dodge(0.9)) +
scale_y_continuous(labels=comma)+
scale_fill_manual(values=c(base_color, rain_color)) +
scale_fill_manual(values=c("grey", rain_color), labels="Not raining", "Raining") +
labs(
title = "Average Hourly Trips by Rain and Trip Distance",
x = "Rain",
y = "Average Hourly Trips",
fill = "Rain"
fill = ""
)+
facet_wrap(~trip_type, scales = "free_y") +
theme(
Expand Down

0 comments on commit 9867036

Please sign in to comment.