Page Menu
Home
c4science
Search
Configure Global Search
Log In
Files
F108039643
mydefinitions.R
No One
Temporary
Actions
Download File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Award Token
Subscribers
None
File Metadata
Details
File Info
Storage
Attached
Created
Sun, Apr 13, 12:16
Size
924 B
Mime Type
text/x-tex
Expires
Tue, Apr 15, 12:16 (2 d)
Engine
blob
Format
Raw Data
Handle
25525666
Attached To
rNUMDATAMOODLE Numerical Data For Moodle
mydefinitions.R
View Options
packages <- c("knitr", "kableExtra", "dplyr")
# Install packages not yet installed
installed_packages <- packages %in% rownames(installed.packages())
if (any(installed_packages == FALSE)) {
install.packages(packages[!installed_packages])
}
library(knitr)
library(kableExtra)
library(dplyr)
knit_hooks$set(document = function(x,options) {
sub('\\usepackage[]{color}', '\\usepackage[]{xcolor}', x, fixed = TRUE)
#paste("\\begin{lstlisting}\n", x, "\\end{lstlisting}\n", sep = "")
})
opts_chunk$set(
fig.path = "fig/"
)
# <<options, echo=FALSE, warning=FALSE, message= FALSE, results = FALSE>>=
# options(digits=3)
# packages <- c("dplyr", "knitr")
# # Install packages not yet installed
# installed_packages <- packages %in% rownames(installed.packages())
# if (any(installed_packages == FALSE)) {
# install.packages(packages[!installed_packages])
# }
# lapply(packages, require, character.only = TRUE)
# @
Event Timeline
Log In to Comment