- "markdown": "---\ntitle: \"Week 2: Time series graphics\"\n---\n\n::: {.cell}\n\n:::\n\n\n\n\n## What you will learn this week\n\n* Different types of plots for time series including time plots, season plots, subseries plots, lag plots and ACF plots.\n* The difference between seasonal patterns and cyclic patterns in time series.\n* What is \"white noise\" and how to identify it.\n\n## Tutorial exercises\n\n- Complete Exercises 1-4 from [Section 2.10 of the book](https://otexts.com/fpp3/graphics-exercises.html).\n- We completed Exercise 5 in last week's lectorial.\n- [Tutorial learning objectives](tute-lo.qmd).\n\n## Exercise solutions\n\n::: {.callout appearance=\"minimal\"}\n<i class=\"bi bi-download\"></i> [Week 2 Tutorial Solution.html](Week2.html){download=\"Week 2 Tutorial Solution.html\"}\n:::\n\n\n## Pre-seminar activities\n\n- Read [Chapter 2 of the textbook](https://otexts.com/fpp3/graphics.html) and watch all embedded videos\n\n\n\n\n\n## Slides for seminar\n\n<embed src='/week2/week2.pdf' type='application/pdf' width='100%' height=465></embed>\n<a href=/week2/week2.pdf class='badge badge-small badge-red'>Download pdf</a>\n\n\n\n\n## Lectorial activities\n\n\n\n\n\n\n\n1. We have introduced various functions for time series graphics including `autoplot()`, `gg_season()`, `gg_subseries()`, `gg_lag()` and `ACF`. Use these functions to explore the quarterly tourism data for the Snowy Mountains.\n\n ```r\n snowy <- tourism |> filter(Region == \"Snowy Mountains\")\n ```\n\n What do you learn?\n\n2. Which time plot corresponds to which ACF plot?\n\n::: {.cell}\n::: {.cell-output-display}\n{width=100%}\n:::\n:::\n\n3. You can compute the daily changes in the Google stock price in 2018 using the code below. Do the daily changes look like white noise?\n\n\\fontsize{11.5}{15}\\sf\n\n\n::: {.cell}\n\n```{.r .cell-code}\ndgoog <- gafa_stock |>\n filter(Symbol == \"GOOG\", year(Date) >= 2018) |>\n mutate(trading_day = row_number()) |>\n update_tsibble(index=trading_day, regular=TRUE) |>\n mutate(diff = difference(Close))\n```\n:::\n\n\\fontsize{14}{16}\\sf\n\n \n\n\n\n\n\n## Seminar code\n\n::: {.callout appearance=\"minimal\"}\n<i class=\"bi bi-download\"></i> [week2.R](week2.R){download=\"week2.R\"}\n:::\n\n\n\n\n\n\n\n## Assignments\n\n* [IA1](../assignments/A1.qmd) is due on Monday 10 March.\n* [GA1](../assignments/G1.qmd) is due on Monday 24 March.\n",
0 commit comments