BaşlayınÜcretsiz Başlayın

Daily plots

Let's now look at the number of rides vs. hour for each day. To start, we'll create a summary dataset for the first full month in the dataset (May) and look at it.

Bu egzersiz

Visualizing Big Data with Trelliscope in R

kursunun bir parçasıdır
Kursu Görüntüle

Egzersiz talimatları

  • Filter the data to the month of May (use start_mon)
  • Count the number of rides for each combination of start_day, start_hod, and membership
  • Use points to plot the number of rides vs. hour of day and color the points based on membership
  • Use facet on start_day, using facet_wrap() and specifying 7 columns for day-of-week alignment

Uygulamalı interaktif egzersiz

Bu örnek kodu tamamlayarak bu egzersizi bitirin.

library(dplyr)
library(ggplot2)

# Compute daily_may
daily_may <- bike %>%
  filter(___) %>%
  group_by(___) %>%
  summarise(n = ___)

# Plot the result
ggplot(daily_may, aes(___, ___, color = ___)) +
  ___ +
  ___
Kodu Düzenle ve Çalıştır