-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathexercise_solutions.Rmd
More file actions
64 lines (47 loc) · 1.46 KB
/
exercise_solutions.Rmd
File metadata and controls
64 lines (47 loc) · 1.46 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
57
58
59
60
61
62
63
64
---
title: "Exercise Solutions"
output:
html_document:
toc: false
---
```{r setup-alex, include=FALSE}
library(knitr)
library(stringr)
knitr::opts_chunk$set(message=FALSE, warning=FALSE, eval=TRUE, echo=FALSE)
suppressPackageStartupMessages(library(dplyr))
suppressPackageStartupMessages(library(stringr))
source('reveal.R')
```
\
Follow the links below for solutions to each of the exercises you have completed on this course. Click on the 'code' buttons to reveal the R code associated with each question.
\
### Day 2
```{r sol_GDE, results='asis', eval = isTRUE(show_text_GDE)}
link_name <- "GLM - Poisson exercise"
file_name <- "GLM_1_Poisson_exercise_solutions"
paste0("- [", link_name, "](", file_name, ".html)") %>%
cat(sep="\n\n")
```
\
### Day 3
```{r sol_lm2, results='asis', eval = isTRUE(show_text_lm2)}
link_name <- "Binomial GLM exercise"
file_name <- "GLM_2_Binomial_exercise_solutions"
paste0("- [", link_name, "](", file_name, ".html)") %>%
cat(sep="\n\n")
```
\
### Day 4
```{r sol_lm1, results='asis', eval = isTRUE(show_text_lm1)}
link_name <- "Bernoulli GLM exercise"
file_name <- "GLM_3_Bernoulli_exercise_solutions"
paste0("- [", link_name, "](", file_name, ".html)") %>%
cat(sep="\n\n")
```
\
```{r code-out, include = FALSE}
sol_files<- list.files(pattern= "_exercise_solutions.Rmd", full.names= F)
for(i in sol_files){
knitr::purl(i, output = paste0('./exercise_solutions/', substr(i, 1, nchar(i)-4), '.R'), quiet = TRUE)
}
```