---
title: "Check for stationarity"
output: html_document
---
  
## Check for stationarity
  
Consider the artificial series `x1` and `x2`:
```{r}
x1 <- c(88, 109, 319, 211, 154, 241, 303, 381, 265, 327, 293, 405, 417, 366, 245, 195, 121, 103, 144, 21)
x2 <- c(26, 156, 236, 526, 509, 537, 699, 768, 982, 968, 956, 1282, 1347, 1187, 1442, 1611, 1600, 1797, 2080, 1973)
```
For each:
  
- Check whether the data behaves stationary
- If it does, calculate its mean and variance
- If not, try to detrend it
