Our primary focus in the previous chapters has been on the attributes and structure of time series data. Starting from this chapter, we are shifting gears and moving toward the analysis phase of time series data. This chapter focuses on one of the essential elements of time series analysis—the decomposition process of time series data to its components: the trend, seasonal, and random components. We will start with the moving average function and see its applications for smoothing time series data, removing seasonality, and estimating a series trend. In addition, we will introduce the decompose function and look at its applications. The topics in this chapter are an introduction to more advanced time series analysis topics that will be introduced later in the book.
In this chapter, we will cover the following topics:
- The moving average...