Chapter 8 Seasonality
To work with seasonal data, we need to turn our data into a ts object, which is a “time-series” object in R. This will allow us to specify the seasonality. It is important that we do not leave out any data in our time series. You data should look like so
Year Month metric.tons
2018 1 1
2018 2 2
2018 3 3
...
2019 1 4
2019 2 6
2019 3 NA
The months are in order and the years are in order.