来自本书网站的快速表述:
melsyd_economy <- ansett %>%
filter(Airports == "MEL-SYD", Class == "Economy") %>%
mutate(Passengers = Passengers/1000)
autoplot(melsyd_economy, Passengers) +
labs(title = "Ansett airlines economy class",
subtitle = "Melbourne-Sydney",
y = "Passengers ('000)")
请注意,x 轴具有基于周索引的异常格式。我想做的是对此进行调整,例如仅显示年份(1989、1990、1991 等)