-
Notifications
You must be signed in to change notification settings - Fork 1
/
setup.r
34 lines (30 loc) · 984 Bytes
/
setup.r
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
# Script run in the book_setup chunk in index.Rmd
pacman::p_load(tidyverse,
data.table,
SASmarkdown,
magrittr,
readxl,
DT,
summarytools,
tidyr,
readr,
haven,
ggplot2,
ggthemes,
broom,
purrr,
servr)
# Windows path
# saspath <- "C:/Program Files/SASHome/SASFoundation/9.4/sas.exe"
# sasopts <- "-nosplash -ls 75"
# Linux (Ubuntu) path
saspath <- "/usr/local/SASHome/SASFoundation/9.4/bin/sas_en"
sasopts <- "-ls 75"
# set default chunk options for RMarkdown
# h/t: https://melindahiggins.netlify.app/post/create-rmarkdown-document-with-sas-code-and-output-sas-engine/;
knitr::opts_chunk$set(
engine.path = list(sas = saspath, sashtml = saspath, saslog = saspath),
engine.opts = list(sas = sasopts, sashtml = sasopts, saslog = sasopts),
comment = NA,
dev = "svg"
)