Show the code
library(tidyverse)
library(nycflights13)DS 350 · Data Wrangling & Visualization
Spencer Payne
Do older aircraft lead to longer delays? I joined the 2013 NYC flights table to aircraft records by tail number, calculated each plane’s age, grouped planes into age bands, and compared departure delays, carriers, and flight distances across those bands.
# A tibble: 5 × 2
age_group n
<chr> <int>
1 0-10 119882
2 11-20 124825
3 21-30 32725
4 >30 1432
5 <NA> 57912

It seems from this chart that the younger planes have longer departure times than the older ones. The 75th percentile of the box is higher the younger a plane is.

It seems to me in this chart that there are not many correlations between the carrier and the ages of the planes that they have.

From what this graph shows about plane ages and distances that the planes travel, it does not seem like there are any correlations between those two variables. Although it is important to note that 21-30 year old planes have the highest average flight distance.