This is an exercise on data wrangling using the flights dataset:
library(tidyverse)
library(nycflights13)
data(flights)
data(airlines)
Select columns in the flights table that contain delay times (note that the function matches
can be used to select columns with names that matches a regular expression. See ?dplyr::select
)
Find the minimum arrival delay (this can be a negative number) in the flights table. Use summarize
.
Find minimum arrival delay (again, can be a negative number) in the flights table for each destination airport. Use group_by' and 'summarize
.
List the name of all airlines and the number of flights for each airline in flights table. The airlines
table has airline names.