-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathemail_cadc_drought_monitoring.Rmd
132 lines (96 loc) · 2.07 KB
/
email_cadc_drought_monitoring.Rmd
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
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
---
title: email
output: blastula::blastula_email
---
<style type = "text/css">
h1, h2, h3 {
font-family: Arvo, "Helvetica Neue", Helvetica, Arial, sans-serif;
font-weight: normal
}
p {
font-family: "Source Sans Pro", "Helvetica Neue", Helvetica, Arial, sans-serif
}
</style>
```{r setup, include=FALSE}
knitr::opts_chunk$set(
echo = FALSE,
warning = FALSE,
message = FALSE,
fontfamily = "Sans Source Pro",
results="asis",
fig.align='center',
fig.cap = ""
)
```
```{r}
# gghdx()
# source("src/email/email_utils.R")
```
```{r, class.output = "banner"}
banner_drib <- drive_dribble %>%
filter(name == "centre_banner.png")
drive_download(banner_drib, path = banner_path <- tempfile(fileext = ".png"))
add_image(
file = banner_path,
alt = "Centre for Humanitarian Data banner",
align = "left",
width = "25%"
)
```
# `r email_txt$title`
## `r email_txt$subtitle`
### `r email_txt$date_header` `r email_txt$status`
```{r}
# m_choro
add_ggplot_custom(
plot_object = m_choro,
alt = "Alert Map",
height = 3.75,
width = 5.5,
html_width = 650
)
```
## `r email_txt$description_title`
`r email_txt$description_content`
```{r PlotDischarge}
add_ggplot_custom(
plot_object = p_rainfall,
alt = "Alert plot",
height = 3.75,
width = 5.5,
html_width = 650
)
```
```{r tblThresholds}
gt_threshold_table %>%
gt::tab_options(
table.font.size = 14,
# table.width = px(500)
table.width = pct(80)
)
```
<!-- **Methodology Update:** -->
<!-- *`r email_txt$methodology_update`* -->
**Forecast data source:** `r email_txt$data_source`
Data accessed `r trimws(format(as_date(Sys.Date()), "%B %Y"))`.
`r email_txt$ref_github`
----
## Contact
`r email_txt$contact_info`
----
```{r FooterLogo}
logo_drib <- drive_dribble %>%
filter(name == "ocha_logo_wide.png")
drive_download(logo_drib, path = logo_path <- tempfile(fileext = ".png"))
add_image(
file = logo_path,
align = "center",
width = "25%"
)
```
<p>
<center>
<b> OCHA Centre For Humanitarian Data </b>
Fluwelen Burgwal 58 | 2511 CJ The Hague | The Netherlands
</center>
</p>