This repository was archived by the owner on Nov 19, 2024. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathdefault.R
More file actions
56 lines (44 loc) · 2.18 KB
/
default.R
File metadata and controls
56 lines (44 loc) · 2.18 KB
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
message(timestamp(quiet = TRUE))
### Project Setup ==================================================================================
library(here)
project_name <- sub("(.*)_[^_]*\\.Rproj$", "\\1", list.files(here(), pattern = ".Rproj$"))
output_directory <- here("outputs", "99-default")
dir.create(output_directory, recursive = TRUE, showWarnings = FALSE, mode = "0775")
### Load Packages ==================================================================================
suppressPackageStartupMessages({
# library(ragg)
# library(ggplot2)
# library(ggtext)
# library(patchwork)
# library(data.table)
# library(future)
# library(future.callr)
# library(future.apply)
})
### project setup ==================================================================================
# plan(future.callr::callr, workers = 40)
# message(sprintf("Number of workers: %d", future::nbrOfWorkers()))
### Tables and Figures Theme =======================================================================
# options(
# ggplot2.discrete.colour = function(...) scale_colour_viridis_d(..., begin = 0.15, end = 0.85),
# ggplot2.discrete.fill = function(...) scale_fill_viridis_d(..., begin = 0.15, end = 0.85),
# ggplot2.continuous.colour = function(...) scale_colour_viridis_c(..., begin = 0.15, end = 0.85),
# ggplot2.continuous.fill = function(...) scale_fill_viridis_c(..., begin = 0.15, end = 0.85)
# )
# theme_set(theme_minimal(base_family = "Verdana"))
# theme_update(
# plot.title.position = "plot",
# plot.caption.position = "plot",
# plot.title = element_markdown(),
# plot.subtitle = element_markdown(face = "italic"),
# plot.caption = element_markdown(face = "italic"),
# axis.title.x = element_markdown(),
# axis.text.x = element_markdown(),
# axis.title.y = element_markdown(),
# axis.text.y = element_markdown()
# )
### Functions ======================================================================================
### Analysis =======================================================================================
### Complete =======================================================================================
message("Success!", appendLF = TRUE)
message(timestamp(quiet = TRUE))