Playback starts YouTube’s embedded player (privacy-enhanced mode).
R Tutorial : Stationarity and Nonstationarity
ChannelDataCampDescription from the creator
Want to learn more? Take the full course at learn.datacamp.com/courses/arima-models-in-r at your own pace. More than a video, you'll learn hands-on coding & quickly apply skills to your daily work.
---
Let's proceed with the basic concepts of stationarity, its importance, and how to coerce nonstationary data to stationarity.
In the context of time series, stationary refers to the stability of the mean - that is, there is no trend stability of the correlation - that is, the correlation structure of the data remains constant over time.
The time series plotted here may help in understanding stationarity better. The left-hand plot is stationary, there is no trend and the time series behaves the same, for example, between time points 1 to 50, 50 to 100, and so on. On the other hand, the plot on the right looks very different between time point 1 to 50 and 150 to 200. The means in these time intervals are different, as is the variability... the end of the series being more variable than the beginning.
Stationarity means that we can use simple averaging to estimate correlation: If the mean is constant, then you can estimate it by the sample average, x-bar, and If the correlation structure is constant, then for example, we can use all the pairs of data that are 1 time unit apart, (x_1, x_2), (x_2, x_3), and so on, to estimate lag 1 correlation. This works because the relationship between contiguous values of the series remains the same over time. Similarly, we can use (x_1, x_3), (x_2, x_4) and so on to estimate the lag 2 correlation.
The Southern Oscillation Index is reasonably stable.... it looks the same in any little segment of time (although there might be some slight trend).
The scatterplots show the correlation in terms of lag. This is called auto-correlation and is the same as the correlation you learned about in regression. The graphic shows that the Southern Oscillation Index, which is a surrogate for sea surface temperature, is positively correlated with itself one month apart, but negatively correlated with itself six months apart (as it is hot in the summer and cold in the winter).
The global temperature deviations are an example of a random walk where the value of the series at time t is the value it was at time t-1 plus a completely random movement. Differencing ("today minus yesterday") can make this kind of process stationery.
The price of chicken is more like "trend stationarity", which is stationary behavior around a simple trend. Differencing works here too.
Finally, if there are trend and heteroscedasticity, logging and differencing can help as in the Johnson and Johnson earnings data set. First, logging positive-valued data can stabilize the variance. Second, differencing the data will detrend it.
#DataCamp #RTutorial #ARIMAModelsinR
---
Let's proceed with the basic concepts of stationarity, its importance, and how to coerce nonstationary data to stationarity.
In the context of time series, stationary refers to the stability of the mean - that is, there is no trend stability of the correlation - that is, the correlation structure of the data remains constant over time.
The time series plotted here may help in understanding stationarity better. The left-hand plot is stationary, there is no trend and the time series behaves the same, for example, between time points 1 to 50, 50 to 100, and so on. On the other hand, the plot on the right looks very different between time point 1 to 50 and 150 to 200. The means in these time intervals are different, as is the variability... the end of the series being more variable than the beginning.
Stationarity means that we can use simple averaging to estimate correlation: If the mean is constant, then you can estimate it by the sample average, x-bar, and If the correlation structure is constant, then for example, we can use all the pairs of data that are 1 time unit apart, (x_1, x_2), (x_2, x_3), and so on, to estimate lag 1 correlation. This works because the relationship between contiguous values of the series remains the same over time. Similarly, we can use (x_1, x_3), (x_2, x_4) and so on to estimate the lag 2 correlation.
The Southern Oscillation Index is reasonably stable.... it looks the same in any little segment of time (although there might be some slight trend).
The scatterplots show the correlation in terms of lag. This is called auto-correlation and is the same as the correlation you learned about in regression. The graphic shows that the Southern Oscillation Index, which is a surrogate for sea surface temperature, is positively correlated with itself one month apart, but negatively correlated with itself six months apart (as it is hot in the summer and cold in the winter).
The global temperature deviations are an example of a random walk where the value of the series at time t is the value it was at time t-1 plus a completely random movement. Differencing ("today minus yesterday") can make this kind of process stationery.
The price of chicken is more like "trend stationarity", which is stationary behavior around a simple trend. Differencing works here too.
Finally, if there are trend and heteroscedasticity, logging and differencing can help as in the Johnson and Johnson earnings data set. First, logging positive-valued data can stabilize the variance. Second, differencing the data will detrend it.
#DataCamp #RTutorial #ARIMAModelsinR
About this tutorial
DataCamp published this 3:14 video tutorial on April 13, 2020. It has been watched 17,668 times on YouTube.
- Channel
- DataCamp
- Category
- Science & Technology
- Duration
- 3:14
- Published
- April 13, 2020
- Views
- 17,668
- Likes
- 205
Tags
Share
This tutorial in other languages
- FRR Tutorial: stationnarité et non-stationnarité
- ESR Tutorial: Estacionariedad y no estacionariedad
- PTR Tutorial: Estacionariedade e não-estacionário
- ITR Tutorial: stazionarietà e non stazionarietà
- DER Tutorial: Stationarität und Nichtstationarität
- NLR Tutorial: Stationariteit en niet-stationariteit
- RUR Учебное пособие: стационарности и нестационарности
- PLR Tutorial: Stacjonarność i niestacjonarności
- JARチュートリアル:定常性と非定常
- ARR البرنامج التعليمي: السكون وNonstationarity
- HIआर ट्यूटोरियल: Stationarity और Nonstationarity
- IDR Tutorial: Stasioneritas dan nonstationarity