diff --git a/01-intro.Rmd b/01-intro.Rmd index 32b947e57cc624d7c96abc2ce109ee0978f28567..a7785a9f427f6a526dc6f47888192a1f4a0d86a5 100644 --- a/01-intro.Rmd +++ b/01-intro.Rmd @@ -1,3 +1,10 @@ # Introduction {#intro} -Background and introduction chapter \ No newline at end of file +Background and introduction chapter + +Equation \@ref(eq:binom) is an example of how to make a referenced equation: + +\begin{equation} + f\left(k\right) = \binom{n}{k} p^k\left(1-p\right)^{n-k} + (\#eq:binom) +\end{equation} \ No newline at end of file diff --git a/03-results-01.Rmd b/03-results-01.Rmd index 86c181e1418bacfde49a4eed1312328932376638..a1b71d03f6cfc8dda96bac5266831c7e965c877c 100644 --- a/03-results-01.Rmd +++ b/03-results-01.Rmd @@ -1,10 +1,18 @@ # First Results {#results-1} -First results chapter. +First results chapter with Figure \@ref(fig:fig1-chunk). -(ref:mpg-plot) Car engine size versus fuel efficiency. The mpg data contains observations collected by the US Environmental Protection Agency on 38 models of car. +(ref:mpg-plot) Car engine size versus fuel efficiency. The mpg data contains observations collected by the US Environmental Protection Agency on 38 models of car. -```{r mpg,echo=FALSE,fig.cap ='(ref:mpg-plot)', fig.scap='Car engine size versus fuel efficiency',out.extra='',fig.align='center',cache=TRUE,warning=FALSE,fig.pos="H"} +```{r fig1-chunk,echo=FALSE,fig.cap ='(ref:mpg-plot)', fig.scap='Car engine size versus fuel efficiency',out.extra='',fig.align='center',cache=TRUE,warning=FALSE,fig.pos="H"} ggplot(data = mpg) + geom_point(mapping = aes(x = displ, y = hwy, color = class)) -``` \ No newline at end of file +``` + +> **Notes** The caption comes from the text following `(ref:fig1-caption)` and +this has to be all one line like so: + +>`(ref:mpg-plot) Car engine size versus fuel efficiency. The mpg data contains observations collected by the US Environmental Protection Agency on 38 models of car.` + +> Whilst the reference number to the figure itself comes from +the code chunk name `fig1-chunk` inside the referencing syntax `\@ref(fig:fig1-chunk)`. \ No newline at end of file diff --git a/_book/thesis-dissertaion.pdf b/_book/thesis-dissertaion.pdf index 06b2dbfb83797608d1246367415bc020d6085aa0..80ffbc75701d2dc1c7d33b03bbc974e589ca7085 100644 Binary files a/_book/thesis-dissertaion.pdf and b/_book/thesis-dissertaion.pdf differ diff --git a/_bookdown_files/thesis-dissertaion_cache/latex/fig1-chunk_8a0f1756c85c83caf0dd32ca80854607.RData b/_bookdown_files/thesis-dissertaion_cache/latex/fig1-chunk_8a0f1756c85c83caf0dd32ca80854607.RData new file mode 100644 index 0000000000000000000000000000000000000000..af4c68256aac8cf88cad19428eb1b62cd2634ee8 Binary files /dev/null and b/_bookdown_files/thesis-dissertaion_cache/latex/fig1-chunk_8a0f1756c85c83caf0dd32ca80854607.RData differ diff --git a/_bookdown_files/thesis-dissertaion_cache/latex/fig1-chunk_8a0f1756c85c83caf0dd32ca80854607.rdb b/_bookdown_files/thesis-dissertaion_cache/latex/fig1-chunk_8a0f1756c85c83caf0dd32ca80854607.rdb new file mode 100644 index 0000000000000000000000000000000000000000..e69de29bb2d1d6434b8b29ae775ad8c2e48c5391 diff --git a/_bookdown_files/thesis-dissertaion_cache/latex/fig1-chunk_8a0f1756c85c83caf0dd32ca80854607.rdx b/_bookdown_files/thesis-dissertaion_cache/latex/fig1-chunk_8a0f1756c85c83caf0dd32ca80854607.rdx new file mode 100644 index 0000000000000000000000000000000000000000..7ef50262db4ae0ff76e788a706e9e0515987d27f Binary files /dev/null and b/_bookdown_files/thesis-dissertaion_cache/latex/fig1-chunk_8a0f1756c85c83caf0dd32ca80854607.rdx differ diff --git a/_bookdown_files/thesis-dissertaion_files/figure-latex/fig1-chunk-1.pdf b/_bookdown_files/thesis-dissertaion_files/figure-latex/fig1-chunk-1.pdf new file mode 100644 index 0000000000000000000000000000000000000000..3d9780b85de6574816a0465eaaa6c254fad10d20 Binary files /dev/null and b/_bookdown_files/thesis-dissertaion_files/figure-latex/fig1-chunk-1.pdf differ diff --git a/_output.yml b/_output.yml index 9d713dfcebdba163799d0466b56e797b8b8bd2dc..b2821df981f60618d3d0b13505eaf4ec7466dab2 100644 --- a/_output.yml +++ b/_output.yml @@ -1,5 +1,5 @@ bookdown::pdf_book: - latex_engine: xelatex + latex_engine: pdflatex includes: in_header: tex-files/preamble.tex keep_tex: yes diff --git a/tex-files/preamble.tex b/tex-files/preamble.tex index 591d36e04ba4594c91be4bf26c9c0e418b1170b2..8e9d7f501ab2b8630a4f49813a92d1c7d61e9af8 100644 --- a/tex-files/preamble.tex +++ b/tex-files/preamble.tex @@ -1,7 +1,8 @@ % Peamble - load all the packages \usepackage[none]{hyphenat} -\usepackage[T1]{fontenc} % Use 8-bit encoding that has 256 glyphs -\usepackage[default,osfigures,scale=0.95]{opensans} % Open sans font +\usepackage[utf8]{inputenc} % For greek letters and othe unicode symbols +\usepackage[scaled]{berasans} % Sans font +\renewcommand*\familydefault{\sfdefault} %% Only if the base font of the document is to be sans serif \usepackage{lmodern} \usepackage{lettrine} % The lettrine is the first enlarged letter at the beginning of the text \usepackage{appendix}