-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy path_setup.qmd
66 lines (54 loc) · 1.31 KB
/
_setup.qmd
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
```{r knit-setup}
#| include: false
#| eval: true
knitr::knit_engines$set(
file = knitr::knit_engines$get("R")
)
knitr::opts_hooks$set(
engine = function(options) {
if (options$engine == "targets") {
options$class.source <- c(options$class.source, "targets-chunk")
options$class.output <- c(options$class.output, "targets-chunk")
}
if (options$engine == "file") {
options$class.source <- c(options$class.source, "file-chunk")
options$class.output <- c(options$class.output, "file-chunk")
}
return(options)
},
eval = function(options) {
if (options$engine %in% c("targets", "file")) {
options$eval <- FALSE
}
return(options)
},
eval = function(options) {
if (options$engine %in% c("targets", "file")) {
options$eval <- FALSE
}
return(options)
}
)
knitr::opts_chunk$set(
collapse = TRUE,
comment = "#>",
fig.width = 8
)
options(
ggplot2.continuous.colour = "viridis",
ggplot2.continuous.fill = "viridis",
ggplot2.discrete.colour = function() {
ggplot2::scale_colour_brewer(
palette = "Paired",
na.value = "grey"
)
} ,
ggplot2.discrete.fill = function() {
ggplot2::scale_fill_brewer(
palette = "Paired",
na.value = "grey"
)
}
)
source("helper_functions.R")
```