├── refs.qmd ├── examples ├── template.pdf └── template.png ├── figures └── monash-logo.jpg ├── .gitignore ├── _extensions └── monashthesis │ ├── fonts.html │ ├── title.tex │ ├── _extension.yml │ └── before-title.tex ├── A-appA.qmd ├── myThesis.Rproj ├── README.md ├── _quarto.yml ├── README.qmd ├── 02-chap2.qmd ├── thesisrefs.bib ├── data └── sales.csv ├── 01-chap1.qmd ├── thesis.scss ├── american-statistical-association.csl ├── index.qmd └── LICENSE /refs.qmd: -------------------------------------------------------------------------------- 1 | # Bibliography {-} 2 | 3 | ::: {#refs} 4 | ::: 5 | -------------------------------------------------------------------------------- /examples/template.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/quarto-monash/thesis/HEAD/examples/template.pdf -------------------------------------------------------------------------------- /examples/template.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/quarto-monash/thesis/HEAD/examples/template.png -------------------------------------------------------------------------------- /figures/monash-logo.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/quarto-monash/thesis/HEAD/figures/monash-logo.jpg -------------------------------------------------------------------------------- /.gitignore: -------------------------------------------------------------------------------- 1 | /.Rproj.user/ 2 | /.quarto/ 3 | /_book/ 4 | /_freeze/ 5 | *_files/ 6 | *_cache/ 7 | fonts.html 8 | -------------------------------------------------------------------------------- /_extensions/monashthesis/fonts.html: -------------------------------------------------------------------------------- 1 | 2 | -------------------------------------------------------------------------------- /A-appA.qmd: -------------------------------------------------------------------------------- 1 | # Additional stuff 2 | 3 | You might put some computer output here, or maybe additional tables. 4 | It is possible to have multiple appendices. Just list them in the appropriate place within `_quarto.yml`. 5 | -------------------------------------------------------------------------------- /myThesis.Rproj: -------------------------------------------------------------------------------- 1 | Version: 1.0 2 | 3 | RestoreWorkspace: No 4 | SaveWorkspace: No 5 | AlwaysSaveHistory: No 6 | 7 | EnableCodeIndexing: Yes 8 | UseSpacesForTab: Yes 9 | NumSpacesForTab: 2 10 | Encoding: UTF-8 11 | 12 | RnwWeave: Sweave 13 | LaTeX: pdfLaTeX 14 | 15 | AutoAppendNewline: Yes 16 | StripTrailingWhitespace: Yes 17 | LineEndingConversion: Posix 18 | 19 | SpellingDictionary: en_AU 20 | -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | # Monash Thesis Template 6 | 7 | This is a Quarto template that assists you in creating a Monash 8 | University thesis. 9 | 10 | ## Installation 11 | 12 | You can create a thesis based on this template with the following 13 | command: 14 | 15 | ``` bash 16 | quarto use template quarto-monash/thesis 17 | ``` 18 | 19 | This will install the extension and create the files that you can use as 20 | a starting place for your thesis. 21 | 22 | [![](examples/template.png)](examples/template.pdf) 23 | -------------------------------------------------------------------------------- /_quarto.yml: -------------------------------------------------------------------------------- 1 | project: 2 | type: book 3 | 4 | book: 5 | title: "This is my thesis" 6 | author: "Susan Su" 7 | chapters: 8 | - text: "Front matter" 9 | file: index.qmd 10 | - "01-chap1.qmd" 11 | - "02-chap2.qmd" 12 | - "refs.qmd" 13 | sidebar: 14 | style: "docked" 15 | 16 | bibliography: thesisrefs.bib 17 | csl: american-statistical-association.csl 18 | degreetype: Doctor of Philosophy 19 | submitted: 2024 20 | affiliation: Department of Econometrics & Business Statistics 21 | degrees: 'B.Sc. (Hons), University of Tangambalanga' 22 | 23 | format: 24 | monashthesis-html: default 25 | monashthesis-pdf: default 26 | -------------------------------------------------------------------------------- /_extensions/monashthesis/title.tex: -------------------------------------------------------------------------------- 1 | \def\maketitle{ 2 | \pagenumbering{roman} 3 | {\sf\thispagestyle{empty}% 4 | \null\vskip-.4cm% 5 | \centerline{\includegraphics[width=12cm]{monash-logo}} 6 | \vspace*{4cm} 7 | \begin{center}\fontsize{24}{28}\sf 8 | \textbf{$title$}\\[2cm] 9 | \fontsize{18}{20}\sf $author$\\[0.2cm] 10 | \fontsize{13}{15}\sf $degrees$ 11 | \vfill 12 | \fontsize{13}{15}\sf A thesis submitted for the degree of\\ $degreetype$\\ at Monash University in \number\the\year\\ 13 | $affiliation$ 14 | \end{center} 15 | \newpage\mbox{}\thispagestyle{empty}\newpage 16 | } 17 | } 18 | 19 | % Title and date 20 | 21 | $if(title)$ 22 | \title{$title$} 23 | $endif$ 24 | $if(subtitle)$ 25 | \usepackage{etoolbox} 26 | \makeatletter 27 | \providecommand{\subtitle}[1]{% add subtitle to \maketitle 28 | \apptocmd{\@title}{\par {\large #1 \par}}{}{} 29 | } 30 | \makeatother 31 | \subtitle{$subtitle$} 32 | $endif$ 33 | \date{$date$} 34 | -------------------------------------------------------------------------------- /README.qmd: -------------------------------------------------------------------------------- 1 | --- 2 | format: gfm 3 | --- 4 | 5 | 6 | 7 | ```{r} 8 | #| include: false 9 | # Create pdf and png version of template 10 | library(tidyverse) 11 | library(quarto) 12 | library(magick) 13 | 14 | # Render template 15 | quarto_render(input = "index.qmd") 16 | # Convert rendered PDF to PNG 17 | image_read_pdf("_book/This-is-my-thesis.pdf", pages = 1) |> 18 | image_montage(geometry = "x1000+25+35", tile = 1, bg = "grey92", shadow = TRUE) |> 19 | image_convert(format = "png") |> 20 | image_write("examples/template.png", ) 21 | # Move pdf to examples folder 22 | fs::file_copy("_book/This-is-my-thesis.pdf", "examples/template.pdf", overwrite = TRUE) 23 | ``` 24 | 25 | # Monash Thesis Template 26 | 27 | This is a Quarto template that assists you in creating a Monash University thesis. 28 | 29 | ## Installation 30 | 31 | You can create a thesis based on this template with the following command: 32 | 33 | ```bash 34 | quarto use template quarto-monash/thesis 35 | ``` 36 | 37 | This will install the extension and create the files that you can use as a starting place for your thesis. 38 | 39 | [![](examples/template.png)](examples/template.pdf) 40 | -------------------------------------------------------------------------------- /_extensions/monashthesis/_extension.yml: -------------------------------------------------------------------------------- 1 | title: Monash Thesis Format Template 2 | author: Rob J Hyndman 3 | version: 2.0.0 4 | contributes: 5 | formats: 6 | common: 7 | date-format: "D MMMM YYYY" 8 | number-depth: 2 9 | toc-depth: 2 10 | number-sections: true 11 | fig-height: 5 12 | fig-width: 8 13 | knitr: 14 | opts_chunk: 15 | echo: false 16 | warning: false 17 | message: false 18 | pdf: 19 | documentclass: report 20 | pdf-engine: pdflatex 21 | papersize: a4 22 | fontsize: 11pt 23 | geometry: 24 | - top=2.5cm 25 | - bottom=2.5cm 26 | - left=2.5cm 27 | - right=2.5cm 28 | block-headings: false 29 | cite-method: biblatex 30 | biblio-style: authoryear-comp 31 | colorlinks: true 32 | linestretch: 1.5 33 | template-partials: 34 | - "before-title.tex" 35 | - "title.tex" 36 | html: 37 | theme: 38 | - cosmo 39 | - thesis.scss 40 | fontsize: 16px 41 | mainfont: "Merriweather, serif" 42 | code-link: true 43 | toc-title: "Sections" 44 | html-math-method: katex 45 | published-title: "Last updated" 46 | format-resources: 47 | - fonts.html 48 | include-in-header: 49 | file: fonts.html 50 | -------------------------------------------------------------------------------- /02-chap2.qmd: -------------------------------------------------------------------------------- 1 | # Literature Review {#sec-litreview} 2 | 3 | This chapter contains a summary of the context in which your research is set. 4 | 5 | Imagine you are writing for your fellow PhD students. Topics that are well-known to them do not have to be included here. But things that they may not know about should be included. 6 | 7 | Resist the temptation to discuss everything you've read in the last few years. And you are not writing a textbook either. This chapter is meant to provide the background necessary to understand the material in subsequent chapters. Stick to that. 8 | 9 | You will need to organize the literature review around themes, and within each theme provide a story explaining the development of ideas to date. In each theme, you should get to the point where your ideas will fit in. But leave your ideas to later chapters. This way it is clear what has been done beforehand, and what new contributions you are making to the research field. 10 | 11 | All citations should be done using markdown notation as shown below. This way, your bibliography will be compiled automatically and correctly. 12 | 13 | ## Exponential smoothing {#sec-expsmooth} 14 | 15 | Exponential smoothing methods were originally developed in the late 1950s [@Brown59;@Brown63;@Holt57;@Winters60]. Because of their computational simplicity and interpretability, they became widely used in practice. 16 | 17 | Empirical studies by @MH79 and @M1comp found little difference in forecast accuracy between exponential smoothing and ARIMA models. This made the family of exponential smoothing procedures an attractive proposition [see @CKOS01]. 18 | 19 | The methods were less popular in academic circles until @OKS97 introduced a state space formulation of some of the methods, which was extended in @HKSG02 to cover the full range of exponential smoothing methods. 20 | -------------------------------------------------------------------------------- /thesisrefs.bib: -------------------------------------------------------------------------------- 1 | @book{Brown59, 2 | author = {R. G. Brown}, 3 | title = {Statistical forecasting for inventory control}, 4 | publisher = {McGraw-Hill, New York}, 5 | year = {1959} 6 | } 7 | 8 | @book{Brown63, 9 | author = {R. G. Brown}, 10 | title = {Smoothing, forecasting and prediction of discrete time series}, 11 | publisher = {Englewood Cliffs, New Jersey: Prentice Hall}, 12 | year = {1963} 13 | } 14 | 15 | @article{CKOS01, 16 | author = {C. Chatfield and A. B. Koehler and J. K. Ord and R. D. Snyder}, 17 | title = {A new look at models for exponential smoothing}, 18 | journal = {The Statistician}, 19 | volume = {50}, 20 | number = {2}, 21 | pages = {147--159}, 22 | year = {2001} 23 | } 24 | 25 | @techreport{Holt57, 26 | author = {C. E. Holt}, 27 | title = {Forecasting trends and seasonals by exponentially weighted averages}, 28 | year = {1957}, 29 | institution = {Carnegie Institute of Technology}, 30 | type = {O.N.R. Memorandum}, 31 | number = {52/1957} 32 | } 33 | 34 | @article{HKSG02, 35 | author = {R. J. Hyndman and A. B. Koehler and R. D. Snyder and S. Grose}, 36 | title = {A state space framework for automatic forecasting using 37 | exponential smoothing methods}, 38 | journal = {International Journal of Forecasting}, 39 | volume = {18}, 40 | number = {3}, 41 | pages = {439--454}, 42 | year = {2002} 43 | } 44 | 45 | @article{M1comp, 46 | author = {S. Makridakis and A. Anderson and R. Carbone and R. Fildes and M. Hibon and 47 | R. Lewandowskiand J. Newton and E. Parzen and R. Winkler}, 48 | title = {The accuracy of extrapolation (time series) methods: results of a forecasting competition}, 49 | journal = {Journal of Forecasting}, 50 | volume = {1}, 51 | number = {}, 52 | pages = {111--153}, 53 | year = {1982} 54 | } 55 | @article{MH79, 56 | author = {S. Makridakis and M. Hibon}, 57 | title = {Accuracy of forecasting: an empirical investigation (with discussion)}, 58 | journal = {Journal of Royal Statistical Society (A)}, 59 | volume = {142}, 60 | number = {}, 61 | pages = {97--145}, 62 | year = {1979} 63 | } 64 | @article{OKS97, 65 | author = {J. K. Ord and A. B. Koehler and R. D. Snyder}, 66 | title = {Estimation and prediction for a class of dynamic nonlinear statistical models}, 67 | journal = {Journal of American Statistical Association}, 68 | volume = {92}, 69 | number = {}, 70 | pages = {1621--1629}, 71 | year = {1997} 72 | } 73 | @article{Winters60, 74 | author = {P. R. Winters}, 75 | title = {Forecasting sales by exponentially weighted moving averages}, 76 | journal = {Management Science}, 77 | volume = {6}, 78 | number = {}, 79 | pages = {324--342}, 80 | year = {1960} 81 | } 82 | 83 | @manual{renv, 84 | title = {{renv}: Project Environments}, 85 | author = {Kevin Ushey}, 86 | year = {2022}, 87 | note = {R package version 0.16.0}, 88 | url = {https://CRAN.R-project.org/package=renv} 89 | } 90 | -------------------------------------------------------------------------------- /data/sales.csv: -------------------------------------------------------------------------------- 1 | Quarter,Sales,AdBudget,GDP 2 | Mar-81,1020.2,659.2,251.8 3 | Jun-81,889.2,589,290.9 4 | Sep-81,795,512.5,290.8 5 | Dec-81,1003.9,614.1,292.4 6 | Mar-82,1057.7,647.2,279.1 7 | Jun-82,944.4,602,254 8 | Sep-82,778.5,530.7,295.6 9 | Dec-82,932.5,608.4,271.7 10 | Mar-83,996.5,637.9,259.6 11 | Jun-83,907.7,582.4,280.5 12 | Sep-83,735.1,506.8,287.2 13 | Dec-83,958.1,606.7,278 14 | Mar-84,1034.1,658.7,256.8 15 | Jun-84,992.8,614.9,271 16 | Sep-84,791.7,489.9,300.9 17 | Dec-84,914.2,586.5,289.8 18 | Mar-85,1106.5,663,266.8 19 | Jun-85,985.1,591.7,273.7 20 | Sep-85,823.9,502.2,301.3 21 | Dec-85,1025.1,616.4,285.6 22 | Mar-86,1064.7,647.1,270.6 23 | Jun-86,981.9,615.5,274.6 24 | Sep-86,828.3,514.8,299.7 25 | Dec-86,940.7,609.1,275.9 26 | Mar-87,991.1,641.3,279.3 27 | Jun-87,1021.2,620.2,290.8 28 | Sep-87,796.7,511.2,295.6 29 | Dec-87,986.6,621.3,271.9 30 | Mar-88,1054.2,645.3,267.4 31 | Jun-88,1018.7,616,281 32 | Sep-88,815.6,503.2,309 33 | Dec-88,1010.6,617.5,266.7 34 | Mar-89,1071.5,642.8,283.5 35 | Jun-89,954,585.6,282.3 36 | Sep-89,822.9,520.6,289.2 37 | Dec-89,867.5,608.6,270.7 38 | Mar-90,1002.3,645.7,266.5 39 | Jun-90,972,597.4,287.9 40 | Sep-90,782.9,499.8,287.6 41 | Dec-90,972.8,601.8,283.4 42 | Mar-91,1108,650.8,266.4 43 | Jun-91,943.7,588.3,292.3 44 | Sep-91,806.1,491.6,330.6 45 | Dec-91,954.2,603.3,286.2 46 | Mar-92,1115.5,663.2,259.2 47 | Jun-92,927.1,614,263.7 48 | Sep-92,800.7,506.3,288.2 49 | Dec-92,955.7,606.2,274.1 50 | Mar-93,1049.8,639.5,287.1 51 | Jun-93,886,585.9,285.5 52 | Sep-93,786.4,492.2,303.7 53 | Dec-93,991.3,610.4,275.6 54 | Mar-94,1113.9,660.8,249.3 55 | Jun-94,924.5,612.2,272.9 56 | Sep-94,771.4,509.2,289.8 57 | Dec-94,949.8,612.1,269.2 58 | Mar-95,990.5,653.2,261.3 59 | Jun-95,1071.4,605.3,292.9 60 | Sep-95,854.1,506.6,304.6 61 | Dec-95,929.8,597.4,276.3 62 | Mar-96,959.6,635.2,268.2 63 | Jun-96,991.1,611.6,293.5 64 | Sep-96,832.9,503.8,311.1 65 | Dec-96,1006.1,609.9,273.7 66 | Mar-97,1040.7,645.2,267.5 67 | Jun-97,1026.3,609.8,271.9 68 | Sep-97,785.9,512.1,308.8 69 | Dec-97,997.6,603.7,282.9 70 | Mar-98,1055,639.4,268.4 71 | Jun-98,925.6,601.6,271.4 72 | Sep-98,805.6,497,292.1 73 | Dec-98,934.1,602.8,287.6 74 | Mar-99,1081.7,647.3,258 75 | Jun-99,1062.3,612.5,282.9 76 | Sep-99,798.8,492.2,295 77 | Dec-99,1014.3,610.8,271.2 78 | Mar-00,1049.5,646.5,275.4 79 | Jun-00,961.7,603.3,284 80 | Sep-00,793.4,503.8,300.9 81 | Dec-00,872.3,598.3,277.4 82 | Mar-01,1014.2,649.4,273.8 83 | Jun-01,952.6,620.2,288.4 84 | Sep-01,792.4,497.9,283.4 85 | Dec-01,922.3,609.2,273.4 86 | Mar-02,1055.9,665.9,271.5 87 | Jun-02,906.2,600.4,283.6 88 | Sep-02,811.2,502.3,290.6 89 | Dec-02,1005.8,605.6,289.1 90 | Mar-03,1013.8,647.6,282.2 91 | Jun-03,905.6,583.5,285.6 92 | Sep-03,957.3,502.5,304 93 | Dec-03,1059.5,625.9,271.5 94 | Mar-04,1090.6,648.7,263.9 95 | Jun-04,998.9,610.7,288.3 96 | Sep-04,866.6,519.1,290.2 97 | Dec-04,1018.7,634.9,284 98 | Mar-05,1112.5,663.1,270.9 99 | Jun-05,997.4,583.3,294.7 100 | Sep-05,826.8,508.6,292.2 101 | Dec-05,992.6,634.2,255.1 102 | -------------------------------------------------------------------------------- /_extensions/monashthesis/before-title.tex: -------------------------------------------------------------------------------- 1 | %% CAPTIONS 2 | \usepackage{caption} 3 | \DeclareCaptionStyle{italic}[justification=centering] 4 | {labelfont={bf},textfont={it},labelsep=colon} 5 | \captionsetup[figure]{style=italic,format=hang,singlelinecheck=true} 6 | \captionsetup[table]{style=italic,format=hang,singlelinecheck=true} 7 | 8 | %% FONT 9 | \usepackage{bera} 10 | \usepackage[charter]{mathdesign} 11 | %\usepackage[scale=0.9]{sourcecodepro} 12 | \usepackage[lf,t]{FiraSans} 13 | \usepackage{fontawesome} 14 | 15 | %% HEADERS AND FOOTERS 16 | \usepackage{fancyhdr} 17 | \pagestyle{fancy} 18 | \rfoot{\Large\sffamily\raisebox{-0.1cm}{\textbf{\thepage}}} 19 | \makeatletter 20 | \lhead{\textsf{\expandafter{\@title}}} 21 | \makeatother 22 | \rhead{} 23 | \cfoot{} 24 | \setlength{\headheight}{15pt} 25 | \renewcommand{\headrulewidth}{0.4pt} 26 | \renewcommand{\footrulewidth}{0.4pt} 27 | \fancypagestyle{plain}{% 28 | \fancyhf{} % clear all header and footer fields 29 | \fancyfoot[C]{\sffamily\thepage} % except the center 30 | \renewcommand{\headrulewidth}{0pt} 31 | \renewcommand{\footrulewidth}{0pt}} 32 | 33 | %% MATHS 34 | \usepackage{bm,amsmath} 35 | \allowdisplaybreaks 36 | 37 | %% GRAPHICS 38 | \makeatletter 39 | \def\fps@figure{htbp} 40 | \makeatother 41 | \setcounter{topnumber}{2} 42 | \setcounter{bottomnumber}{2} 43 | \setcounter{totalnumber}{4} 44 | \renewcommand{\topfraction}{0.85} 45 | \renewcommand{\bottomfraction}{0.85} 46 | \renewcommand{\textfraction}{0.15} 47 | \renewcommand{\floatpagefraction}{0.8} 48 | \graphicspath{{figures/}} 49 | 50 | %% SECTION TITLES 51 | \usepackage[compact,sf,bf]{titlesec} 52 | \titleformat*{\section}{\Large\sf\bfseries} 53 | \titleformat*{\subsection}{\large\sf\bfseries} 54 | \titleformat*{\subsubsection}{\sf\bfseries} 55 | \titlespacing{\section}{0pt}{*5}{*1} 56 | \titlespacing{\subsection}{0pt}{*2}{*0.2} 57 | \titlespacing{\subsubsection}{0pt}{*1}{*0.1} 58 | 59 | %% TABLES 60 | \usepackage{booktabs,tabu} 61 | 62 | %% BIBLIOGRAPHY. 63 | 64 | \makeatletter 65 | \@ifpackageloaded{biblatex}{ 66 | \ExecuteBibliographyOptions{bibencoding=utf8,minnames=1,maxnames=3, maxbibnames=99,dashed=false,terseinits=true,giveninits=true,uniquename=false,uniquelist=false,doi=false, isbn=false,url=true,sortcites=false} 67 | \DeclareFieldFormat{url}{\texttt{\url{#1}}} 68 | \DeclareFieldFormat[article]{pages}{#1} 69 | \DeclareFieldFormat[inproceedings]{pages}{\lowercase{pp.}#1} 70 | \DeclareFieldFormat[incollection]{pages}{\lowercase{pp.}#1} 71 | \DeclareFieldFormat[article]{volume}{\mkbibbold{#1}} 72 | \DeclareFieldFormat[article]{number}{\mkbibparens{#1}} 73 | \DeclareFieldFormat[article]{title}{\MakeCapital{#1}} 74 | \DeclareFieldFormat[article]{url}{} 75 | \DeclareFieldFormat[inproceedings]{title}{#1} 76 | \DeclareFieldFormat{shorthandwidth}{#1} 77 | \usepackage{xpatch} 78 | \xpatchbibmacro{volume+number+eid}{\setunit*{\adddot}}{}{}{} 79 | % Remove In: for an article. 80 | \renewbibmacro{in:}{% 81 | \ifentrytype{article}{}{% 82 | \printtext{\bibstring{in}\intitlepunct}}} 83 | \AtEveryBibitem{\clearfield{month}} 84 | \AtEveryCitekey{\clearfield{month}} 85 | \DeclareDelimFormat[cbx@textcite]{nameyeardelim}{\addspace} 86 | \renewcommand*{\finalnamedelim}{\addspace\&\space} 87 | }{} 88 | \makeatother 89 | 90 | 91 | \hypersetup{ 92 | pdfcreator={Quarto -> pandoc -> LaTeX -> pdf} 93 | } 94 | 95 | 96 | %% PAGE BREAKING to avoid widows and orphans 97 | \clubpenalty = 2000 98 | \widowpenalty = 2000 99 | \usepackage{microtype} 100 | -------------------------------------------------------------------------------- /01-chap1.qmd: -------------------------------------------------------------------------------- 1 | # Introduction {#sec-intro} 2 | 3 | ```{r} 4 | #| label: load_packages 5 | #| include: false 6 | library(dplyr) 7 | library(ggplot2) 8 | library(tidyr) 9 | library(tsibble) 10 | library(feasts) 11 | library(fable) 12 | ``` 13 | 14 | This is where you introduce the main ideas of your thesis, and an overview of the context and background. 15 | 16 | In a PhD, Chapter 2 would normally contain a literature review. Typically, Chapters 3--5 would contain your own contributions. Think of each of these as potential papers to be submitted to journals. Finally, Chapter 6 provides some concluding remarks, discussion, ideas for future research, and so on. Appendixes can contain additional material that don't fit into any chapters, but that you want to put on record. For example, additional tables, output, etc. 17 | 18 | ## Quarto 19 | 20 | In this template, the rest of the chapter shows how to use quarto. The big advantage of using quarto is that it allows you to include your R or Python code directly into your thesis, to ensure there are no errors in copying and pasting, and that everything is reproducible. It also helps you stay better organized. 21 | 22 | For details on using Quarto, see . 23 | 24 | ## Data 25 | 26 | Included in this template is a file called `sales.csv`. We can load in this data set using the following code: 27 | 28 | ```{r} 29 | #| label: load_data 30 | #| echo: true 31 | #| message: false 32 | sales <- readr::read_csv(here::here("data/sales.csv")) |> 33 | mutate( 34 | Quarter = as.Date(paste0("01-", Quarter), "%d-%b-%y"), 35 | Quarter = yearquarter(Quarter) 36 | ) |> 37 | as_tsibble(index = Quarter) 38 | ``` 39 | 40 | Any data you use in your thesis can go into the `data` directory. The data should be in exactly the format you obtained it. Do no editing or manipulation of the data prior to including it in the `data` directory. Any data munging should be scripted and form part of your thesis files (possibly hidden in the output). 41 | 42 | ## Figures 43 | 44 | @fig-deaths shows time plots of the data we just loaded. Notice how figure captions and references work. Chunk names can be used as figure labels with `fig-` prefixed. Never manually type figure numbers, as they can change when you add or delete figures. This way, the figure numbering is always correct. 45 | 46 | ```{r} 47 | #| label: fig-deaths 48 | #| fig-cap: "Quarterly sales, advertising and GDP data." 49 | sales |> 50 | pivot_longer(Sales:GDP) |> 51 | autoplot(value) + 52 | facet_grid(name ~ ., scales = "free_y") + 53 | theme(legend.position = "none") 54 | ``` 55 | 56 | ## Results from analyses 57 | 58 | We can fit a regression model to the sales data. 59 | 60 | ```{r} 61 | #| echo: false 62 | fit <- sales |> 63 | model(arima = TSLM(Sales ~ GDP + AdBudget)) 64 | coef <- tidy(fit) 65 | gdp <- coef |> 66 | filter(term == "GDP") |> 67 | pull(estimate) 68 | adbudget <- coef |> 69 | filter(term == "AdBudget") |> 70 | pull(estimate) 71 | ``` 72 | 73 | If $y_t$ denotes the sales in quarter $t$, $x_t$ denotes the corresponding advertising budget and $z_t$ denotes the GDP, then the resulting model is: 74 | $$ 75 | y_t = \beta x_t + \gamma z_t + \varepsilon_t 76 | $$ {#eq-drm} 77 | where 78 | $\hat{\beta} = `r sprintf("%.2f", adbudget)`$, 79 | and 80 | $\hat{\gamma} = `r sprintf("%.2f", gdp)`$. 81 | We can reference this equation using @eq-drm. 82 | 83 | ## Tables 84 | 85 | We can also make a nice summary table of the coefficients, as shown in @tbl-coef 86 | 87 | ```{r} 88 | #| label: tbl-coef 89 | #| tbl-cap: "Coefficients from the fitted model." 90 | tidy(fit) |> 91 | select(term, estimate, p.value) |> 92 | rename(Coefficient = term, Estimate = estimate, `P value` = p.value) |> 93 | knitr::kable(booktabs = TRUE, digits = 2) 94 | ``` 95 | 96 | Again, notice the use of labels and references to automatically generate table numbers. 97 | -------------------------------------------------------------------------------- /thesis.scss: -------------------------------------------------------------------------------- 1 | /*-- scss:defaults --*/ 2 | $theme-main: #253b72; 3 | $theme-gray: #ebebeb; 4 | $theme-yellow: #F4BA02; 5 | $theme-orange: #f49b02; 6 | 7 | $body-bg: lighten($theme-gray, 20%); 8 | $body-color: darken($theme-gray, 70%); 9 | $link-color: $theme-main; 10 | $primary: $theme-main; 11 | $sidebar-bg: lighten($theme-main, 15%); 12 | $sidebar-fg: lighten($theme-gray, 10%); 13 | 14 | $font-family-sans-serif: 'Fira Sans', sans-serif; 15 | $font-family-monospace: 'Hack', monospace; 16 | 17 | $h1-font-size: 1.5rem !default; 18 | $h2-font-size: 1.5rem !default; 19 | $h3-font-size: 1.3rem !default; 20 | $h4-font-size: 1.1rem !default; 21 | $h5-font-size: 1rem !default; 22 | 23 | $code-block-bg: $theme-gray; 24 | $code-color: $body-color; 25 | 26 | /*-- scss:rules --*/ 27 | 28 | h1.title { 29 | font-size: 2rem !important; 30 | } 31 | 32 | h1, 33 | h2, 34 | h3, 35 | h4 { 36 | color: $theme-main; 37 | font-family: $font-family-sans-serif; 38 | font-weight: bold; 39 | } 40 | 41 | h1, h2 { 42 | border-bottom: 2px solid $theme-main; 43 | margin-top: 50px !important; 44 | } 45 | 46 | h4, h5 { 47 | color: $body-color; 48 | font-family: $font-family-sans-serif; 49 | font-weight: bold; 50 | } 51 | .header-section-number { 52 | color: $theme-main; 53 | } 54 | 55 | a { 56 | color: saturate($theme-main, 50%); 57 | text-decoration: none; 58 | } 59 | 60 | a:hover { 61 | color: saturate($theme-main, 100%); 62 | font-weight: bold; 63 | } 64 | 65 | dt { 66 | color: $theme-main; 67 | } 68 | 69 | dd { 70 | margin-bottom: 12px; 71 | margin-left: 20px; 72 | padding-left: 20px; 73 | } 74 | 75 | .quarto-title-banner { 76 | background-color: lighten($theme-gray, 20%) !important; 77 | color: $theme-main; 78 | font-family: $font-family-sans-serif; 79 | } 80 | 81 | .quarto-title-meta,.quarto-title-meta-author { 82 | font-family: $font-family-sans-serif; 83 | color: $theme-main; 84 | } 85 | 86 | .quarto-title-banner,.quarto-secondary-nav h1 { 87 | border-bottom: 0px; 88 | color: $theme-main; 89 | } 90 | 91 | .panel-caption, .figure-caption, .subfigure-caption, .table-caption, figcaption.quarto-float-caption, caption { 92 | font-family: $font-family-sans-serif; 93 | color: darken($theme-gray, 70%); 94 | background-color: $theme-gray; 95 | padding-left: 20px; 96 | text-align: left; 97 | } 98 | 99 | .figure { 100 | display: block; 101 | } 102 | 103 | table { 104 | background: lighten($theme-gray, 50%); 105 | border: 0px; 106 | } 107 | 108 | table td, table th { 109 | border: 1px; 110 | font-size: 0.9rem; 111 | height: 12px; 112 | line-height: 1.2; 113 | padding: 0; 114 | cellpadding: 0; 115 | cellspacing: 0; 116 | text-shadow: none; 117 | } 118 | 119 | th { 120 | color: #ffffff !important; 121 | background-color: lighten($theme-main, 20%) !important; 122 | font-weight: bold; 123 | } 124 | td { 125 | background-color: lighten($theme-gray, 60%) !important; 126 | } 127 | 128 | blockquote { 129 | quotes: none; 130 | text-shadow: none; 131 | color: darken($theme-gray, 80%) !important; 132 | background: lighten($theme-main, 65%) !important; 133 | padding: 7px 20px 7px 20px; 134 | -moz-border-radius: 5px; 135 | -webkit-border-radius: 5px; 136 | border-left: 0px; 137 | } 138 | 139 | pre code { 140 | color: $body-color !important; 141 | background-color: $code-block-bg; 142 | -moz-border-radius: 5px; 143 | -webkit-border-radius: 5px; 144 | } 145 | 146 | div.sourceCode, div.sourceCode pre.sourceCode { 147 | color: $body-color; 148 | } 149 | 150 | .quarto-page-breadcrumbs .breadcrumb-item+.breadcrumb-item, .quarto-page-breadcrumbs .breadcrumb-item { 151 | font-family: $font-family-sans-serif; 152 | } 153 | 154 | div.sidebar.sidebar-navigation.rollup.quarto-sidebar-toggle-contents, nav.sidebar.sidebar-navigation:not(.rollup) { 155 | background-color: $theme-main !important; 156 | color: lighten($theme-gray, 50%) !important; 157 | font-family: $font-family-sans-serif; 158 | line-height: 1.2; 159 | } 160 | 161 | .sidebar-navigation .sidebar-item { 162 | font-size: .85rem; 163 | line-height: 1.2; 164 | margin-top: 0.3em; 165 | margin-bottom: 0em; 166 | } 167 | 168 | .sidebar { 169 | font-family: $font-family-sans-serif; 170 | background-color: lighten($theme-gray, 50%); 171 | color: $theme-main; 172 | } 173 | 174 | .sidebar-title { 175 | padding-left: 0 !important; 176 | text-indent: 0 !important; 177 | font-weight: bold; 178 | } 179 | 180 | .sidebar-title>a:hover { 181 | color: $theme-orange !important; 182 | } 183 | 184 | .sidebar-navigation, .sidebar-item { 185 | font-family: $font-family-sans-serif; 186 | color: lighten($theme-gray, 50%); 187 | background-color: $theme-main !important; 188 | } 189 | 190 | .sidebar nav[role=doc-toc] ul>li>ul>li>a.active { 191 | color: saturate($theme-main, 60%) !important; 192 | border-left: 2px solid saturate($theme-main, 60%) !important; 193 | } 194 | 195 | .sidebar nav[role=doc-toc] ul>li>a.active { 196 | color: saturate($theme-main, 60%) !important; 197 | border-left: 1px solid saturate($theme-main, 60%) !important; 198 | } 199 | 200 | .sidebar nav[role=doc-toc] a:hover { 201 | color: saturate($theme-main, 60%) !important; 202 | background-color: lighten($theme-gray, 50%); 203 | } 204 | 205 | .sidebar nav[role=doc-toc] ul>li>a:hover, .sidebar nav[role=doc-toc] ul>li>ul>li>a:hover { 206 | color: saturate($theme-main, 60%) !important; 207 | } 208 | 209 | .sidebar-navigation { 210 | background-color: $theme-main !important; 211 | } 212 | 213 | .sidebar-navigation,.sidebar-item a { 214 | color: lighten($theme-gray, 50%) !important; 215 | } 216 | 217 | #quarto-sidebar .menu-text { 218 | display: flex; 219 | } 220 | #quarto-sidebar .chapter-number { 221 | display: block; 222 | width: 1.5em; 223 | text-align: right; 224 | } 225 | #quarto-sidebar .chapter-title { 226 | color: inherit !important; 227 | background-color: inherit !important; 228 | display: block; 229 | padding-left: 8px; 230 | text-indent: -2px; 231 | width: 100%; 232 | } 233 | 234 | .sidebar-item .chapter-number { 235 | color: inherit !important; 236 | background-color: inherit !important; 237 | } 238 | 239 | .sidebar-navigation,.sidebar-item a.active { 240 | color: $theme-yellow !important; 241 | } 242 | 243 | .sidebar-item a:hover { 244 | color: $theme-orange !important; 245 | } 246 | 247 | .page-navigation a:hover { 248 | color: saturate($theme-main, 60%) !important; 249 | } 250 | 251 | .csl-entry { 252 | padding-left: 22px ; 253 | text-indent: -22px ; 254 | } 255 | 256 | .nav-footer,.nav-page-text { 257 | font-family: $font-family-sans-serif; 258 | min-height: 1em; 259 | } 260 | 261 | .katex { font-size: 1.1em !important; } 262 | -------------------------------------------------------------------------------- /american-statistical-association.csl: -------------------------------------------------------------------------------- 1 | 2 | 190 | -------------------------------------------------------------------------------- /index.qmd: -------------------------------------------------------------------------------- 1 | ::: {.content-visible when-format="html"} 2 | 3 | A thesis submitted for the degree of {{< meta degreetype >}} at Monash University, {{< meta affiliation >}}. 4 | 5 | ::: 6 | 7 | # Copyright notice {-} 8 | 9 | ```{r} 10 | #| output: asis 11 | cat("Produced on",format(Sys.Date(), "%e %B %Y.\n\n")) 12 | cat("© {{< meta author >}} (",format(Sys.Date(), "%Y"),").", sep="") 13 | ``` 14 | 15 | # Abstract {-} 16 | 17 | The abstract should outline the main approach and findings of the thesis and must not be more than 500 words. 18 | 19 | 22 | 23 | # Declaration {-} 24 | 25 | > Use only one of the following declarations (Standard thesis or Thesis including published works declaration) and remove the other. 26 | 27 | ### Standard thesis 28 | 29 | This thesis is an original work of my research and contains no material which has been accepted for the award of any other degree or diploma at any university or equivalent institution and that, to the best of my knowledge and belief, this thesis contains no material previously published or written by another person, except where due reference is made in the text of the thesis. 30 | 31 | Student name: 32 | 33 | Student signature: 34 | 35 | Date: 36 | 37 | #### Publications during enrolment {-} 38 | 39 | > Remove this section if you do not have publications. 40 | 41 | The material in @sec-intro has been submitted to the journal *Journal of Impossible Results* for possible publication. 42 | 43 | The contribution in @sec-litreview of this thesis was presented in the International Symposium on Nonsense held in Dublin, Ireland, in July 2022. 44 | 45 | #### Reproducibility statement 46 | 47 | This thesis is written using Quarto with renv [@renv] to create a reproducible environment. All materials (including the data sets and source files) required to reproduce this document can be found at the Github repository [`github.com/SusanSu/thesis`](https://github.com/SusanSu/thesis). 48 | 49 | This work is licensed under a [Creative Commons Attribution-NonCommercial-ShareAlike 4.0 International License](http://creativecommons.org/licenses/by-nc-sa/4.0/). 50 | 51 | ### Thesis including published works declaration 52 | 53 | I hereby declare that this thesis contains no material which has been accepted for the award of any other degree or diploma at any university or equivalent institution and that, to the best of my knowledge and belief, this thesis contains no material previously published or written by another person, except where due reference is made in the text of the thesis. 54 | 55 | This thesis includes ?? original papers published in peer reviewed journals and ?? submitted publications. The core theme of the thesis is ??. The ideas, development and writing up of all the papers in the thesis were the principal responsibility of myself, the student, working within the Department of Econometrics & Business Statistics under the supervision of ?? 56 | 57 | (The inclusion of co-authors reflects the fact that the work came from active collaboration between researchers and acknowledges input into team-based research.) 58 | 59 | In the case of (??insert chapter numbers) my contribution to the work involved the following: 60 | 61 | 62 | ```{r} 63 | #| message: false 64 | #| echo: false 65 | library(tidyverse) 66 | library(knitr) 67 | library(kableExtra) 68 | tab <- tribble( 69 | ~`Thesis chapter`, ~`Publication title`, ~Status, ~`Nature and % of student contribution`, ~`Nature and % of coauthors' contribution`, ~`Coauthors are Monash students`, 70 | 2, "The life cycle of Mongolian crickets", "Submitted", "Concept and data analysis, writing first draft: 60%", "Shu Xu, input into manuscript: 25%; Eddie Betts, input into manuscript: 15%", "Shu Xu: No; Eddie Betts: Yes" 71 | ) 72 | ``` 73 | 74 | ::: {.content-visible when-format="html"} 75 | 76 | ```{r} 77 | tab |> 78 | kable() |> 79 | row_spec(0, align = "l") 80 | ``` 81 | 82 | ::: 83 | 84 | ::: {.content-visible when-format="pdf"} 85 | 86 | ```{r} 87 | tab |> 88 | kable(booktabs = TRUE, format = "latex") |> 89 | kable_styling(full_width = TRUE, font_size = 10, latex_options = "scale_down") |> 90 | column_spec(1, width = "1.2cm") |> 91 | column_spec(c(2, 4:6), width = "2.6cm") |> 92 | row_spec(0, align = "l", bold = TRUE) 93 | ``` 94 | 95 | ::: 96 | 97 | I have / have not renumbered sections of submitted or published papers in order to generate a consistent presentation within the thesis. 98 | 99 | Student name: 100 | 101 | Student signature: 102 | 103 | Date: 104 | 105 | I hereby certify that the above declaration correctly reflects the nature and extent of the student’s and co-authors’ contributions to this work. In instances where I am not the responsible author I have consulted with the responsible author to agree on the respective contributions of the authors. 106 | 107 | Main Supervisor name: 108 | 109 | Main Supervisor signature: 110 | 111 | Date: 112 | 113 | # Acknowledgements {-} 114 | 115 | I would like to thank my pet goldfish for ... 116 | 117 | > In accordance with Chapter 7.1.4 of the research degrees handbook, if you have engaged the services of a professional editor, you must provide their name and a brief description of the service rendered. If the professional editor's current or former area of academic specialisation is similar your own, this too should be stated as it may suggest to examiners that the editor's advice to the student has extended beyond guidance on English expression to affect the substance and structure of the thesis. 118 | 119 | > If you have used generative artificial intelligence (AI) technologies, you must include a written acknowledgment of the use and its extent. Your acknowledgement should at a minimum specify which technology was used, include explicit description on how the information was generated, and explain how the output was used in your work. Below is a suggested format: 120 | 121 | > “I acknowledge the use of [insert AI system(s) and link] to [specific use of generative artificial intelligence]. The output from these was used to [explain use].” 122 | 123 | > Free text section for you to record your acknowledgment and gratitude for the more general academic input and support such as financial support from grants and scholarships and the non-academic support you have received during the course of your enrolment. If you are a recipient of the “Australian Government Research Training Program Scholarship”, you are required to include the following statement: 124 | 125 | > > “This research was supported by an Australian Government Research Training Program (RTP) Scholarship.” 126 | 127 | > You may also wish to acknowledge significant and substantial contribution made by others to the research, work and writing represented and/or reported in the thesis. These could include significant contributions to: the conception and design of the project; non-routine technical work; analysis and interpretation of research data; drafting significant parts of the work or critically revising it to contribute to the interpretation. 128 | 129 | 132 | 133 | \clearpage\pagenumbering{arabic}\setcounter{page}{1} 134 | -------------------------------------------------------------------------------- /LICENSE: -------------------------------------------------------------------------------- 1 | Creative Commons Legal Code 2 | 3 | CC0 1.0 Universal 4 | 5 | CREATIVE COMMONS CORPORATION IS NOT A LAW FIRM AND DOES NOT PROVIDE 6 | LEGAL SERVICES. DISTRIBUTION OF THIS DOCUMENT DOES NOT CREATE AN 7 | ATTORNEY-CLIENT RELATIONSHIP. CREATIVE COMMONS PROVIDES THIS 8 | INFORMATION ON AN "AS-IS" BASIS. CREATIVE COMMONS MAKES NO WARRANTIES 9 | REGARDING THE USE OF THIS DOCUMENT OR THE INFORMATION OR WORKS 10 | PROVIDED HEREUNDER, AND DISCLAIMS LIABILITY FOR DAMAGES RESULTING FROM 11 | THE USE OF THIS DOCUMENT OR THE INFORMATION OR WORKS PROVIDED 12 | HEREUNDER. 13 | 14 | Statement of Purpose 15 | 16 | The laws of most jurisdictions throughout the world automatically confer 17 | exclusive Copyright and Related Rights (defined below) upon the creator 18 | and subsequent owner(s) (each and all, an "owner") of an original work of 19 | authorship and/or a database (each, a "Work"). 20 | 21 | Certain owners wish to permanently relinquish those rights to a Work for 22 | the purpose of contributing to a commons of creative, cultural and 23 | scientific works ("Commons") that the public can reliably and without fear 24 | of later claims of infringement build upon, modify, incorporate in other 25 | works, reuse and redistribute as freely as possible in any form whatsoever 26 | and for any purposes, including without limitation commercial purposes. 27 | These owners may contribute to the Commons to promote the ideal of a free 28 | culture and the further production of creative, cultural and scientific 29 | works, or to gain reputation or greater distribution for their Work in 30 | part through the use and efforts of others. 31 | 32 | For these and/or other purposes and motivations, and without any 33 | expectation of additional consideration or compensation, the person 34 | associating CC0 with a Work (the "Affirmer"), to the extent that he or she 35 | is an owner of Copyright and Related Rights in the Work, voluntarily 36 | elects to apply CC0 to the Work and publicly distribute the Work under its 37 | terms, with knowledge of his or her Copyright and Related Rights in the 38 | Work and the meaning and intended legal effect of CC0 on those rights. 39 | 40 | 1. Copyright and Related Rights. A Work made available under CC0 may be 41 | protected by copyright and related or neighboring rights ("Copyright and 42 | Related Rights"). Copyright and Related Rights include, but are not 43 | limited to, the following: 44 | 45 | i. the right to reproduce, adapt, distribute, perform, display, 46 | communicate, and translate a Work; 47 | ii. moral rights retained by the original author(s) and/or performer(s); 48 | iii. publicity and privacy rights pertaining to a person's image or 49 | likeness depicted in a Work; 50 | iv. rights protecting against unfair competition in regards to a Work, 51 | subject to the limitations in paragraph 4(a), below; 52 | v. rights protecting the extraction, dissemination, use and reuse of data 53 | in a Work; 54 | vi. database rights (such as those arising under Directive 96/9/EC of the 55 | European Parliament and of the Council of 11 March 1996 on the legal 56 | protection of databases, and under any national implementation 57 | thereof, including any amended or successor version of such 58 | directive); and 59 | vii. other similar, equivalent or corresponding rights throughout the 60 | world based on applicable law or treaty, and any national 61 | implementations thereof. 62 | 63 | 2. Waiver. To the greatest extent permitted by, but not in contravention 64 | of, applicable law, Affirmer hereby overtly, fully, permanently, 65 | irrevocably and unconditionally waives, abandons, and surrenders all of 66 | Affirmer's Copyright and Related Rights and associated claims and causes 67 | of action, whether now known or unknown (including existing as well as 68 | future claims and causes of action), in the Work (i) in all territories 69 | worldwide, (ii) for the maximum duration provided by applicable law or 70 | treaty (including future time extensions), (iii) in any current or future 71 | medium and for any number of copies, and (iv) for any purpose whatsoever, 72 | including without limitation commercial, advertising or promotional 73 | purposes (the "Waiver"). Affirmer makes the Waiver for the benefit of each 74 | member of the public at large and to the detriment of Affirmer's heirs and 75 | successors, fully intending that such Waiver shall not be subject to 76 | revocation, rescission, cancellation, termination, or any other legal or 77 | equitable action to disrupt the quiet enjoyment of the Work by the public 78 | as contemplated by Affirmer's express Statement of Purpose. 79 | 80 | 3. Public License Fallback. Should any part of the Waiver for any reason 81 | be judged legally invalid or ineffective under applicable law, then the 82 | Waiver shall be preserved to the maximum extent permitted taking into 83 | account Affirmer's express Statement of Purpose. In addition, to the 84 | extent the Waiver is so judged Affirmer hereby grants to each affected 85 | person a royalty-free, non transferable, non sublicensable, non exclusive, 86 | irrevocable and unconditional license to exercise Affirmer's Copyright and 87 | Related Rights in the Work (i) in all territories worldwide, (ii) for the 88 | maximum duration provided by applicable law or treaty (including future 89 | time extensions), (iii) in any current or future medium and for any number 90 | of copies, and (iv) for any purpose whatsoever, including without 91 | limitation commercial, advertising or promotional purposes (the 92 | "License"). The License shall be deemed effective as of the date CC0 was 93 | applied by Affirmer to the Work. Should any part of the License for any 94 | reason be judged legally invalid or ineffective under applicable law, such 95 | partial invalidity or ineffectiveness shall not invalidate the remainder 96 | of the License, and in such case Affirmer hereby affirms that he or she 97 | will not (i) exercise any of his or her remaining Copyright and Related 98 | Rights in the Work or (ii) assert any associated claims and causes of 99 | action with respect to the Work, in either case contrary to Affirmer's 100 | express Statement of Purpose. 101 | 102 | 4. Limitations and Disclaimers. 103 | 104 | a. No trademark or patent rights held by Affirmer are waived, abandoned, 105 | surrendered, licensed or otherwise affected by this document. 106 | b. Affirmer offers the Work as-is and makes no representations or 107 | warranties of any kind concerning the Work, express, implied, 108 | statutory or otherwise, including without limitation warranties of 109 | title, merchantability, fitness for a particular purpose, non 110 | infringement, or the absence of latent or other defects, accuracy, or 111 | the present or absence of errors, whether or not discoverable, all to 112 | the greatest extent permissible under applicable law. 113 | c. Affirmer disclaims responsibility for clearing rights of other persons 114 | that may apply to the Work or any use thereof, including without 115 | limitation any person's Copyright and Related Rights in the Work. 116 | Further, Affirmer disclaims responsibility for obtaining any necessary 117 | consents, permissions or other rights required for any use of the 118 | Work. 119 | d. Affirmer understands and acknowledges that Creative Commons is not a 120 | party to this document and has no duty or obligation with respect to 121 | this CC0 or use of the Work. 122 | --------------------------------------------------------------------------------