fix vignette

This commit is contained in:
2021-07-28 21:07:07 +02:00
parent 63441d886c
commit d42a039b31
5 changed files with 9 additions and 1 deletions
+2
View File
@@ -1,2 +1,4 @@
^doc$
^Meta$
^.*\.Rproj$
^\.Rproj\.user$
+2
View File
@@ -6,3 +6,5 @@
!/reports/*.tex
/csv/*
/parlament_49_53_texts/
.Rproj.user
*.Rproj
+2
View File
@@ -2,7 +2,9 @@
export(fetch_all)
export(read_all)
export(read_from_csv)
export(repair)
export(write_to_csv)
import(dplyr)
import(pbapply)
import(purrr)
+2
View File
@@ -189,6 +189,7 @@ parse_rednerliste <- function(rednerliste_xml) {
rolle_lang = d["rolle_lang",])
}
#' @export
write_to_csv <- function(tables, path="csv/", create=F) {
check_directory(path, create)
write.table(tables$redner, str_c(path, "redner.csv"))
@@ -197,6 +198,7 @@ write_to_csv <- function(tables, path="csv/", create=F) {
write.table(tables$comments, str_c(path, "comments.csv"))
}
#' @export
read_from_csv <- function(path="csv/") {
list(redner = read.table(str_c(path, "redner.csv")) %>%
tibble() %>%
+1 -1
View File
@@ -39,7 +39,7 @@ the result into more descriptive variables.
For development purposes, we load the tables from csv files.
```{r}
tables <- read_from_csv('csv/')
tables <- read_from_csv('../csv/')
comments <- tables$comments
reden <- tables$reden