Include Boulevard-/Wissenschaftszeitungen in Zeitungen
Change-Id: I032125f4cfd297efeda88d2b85e913f4bb343d48
diff --git a/shiny/app.R b/shiny/app.R
index 80159a2..3244382 100644
--- a/shiny/app.R
+++ b/shiny/app.R
@@ -167,7 +167,7 @@
corpus <- vcFromString(input$cq)
texttypes <-
- c("/Zeitung.*/", "/(Zeitschrift|Magazin).*/", "/Agenturmeldung.*/", "/Enzyklopädie.*/", "/.*Diskussion.*/", "/Roman.*/", "/Newsgroup.*/", "/Tagebuch.*/", "/Sachbuch.*/")
+ c("/[^:]*[Zz]eitung.*/", "/(Zeitschrift|Magazin).*/", "/Agenturmeldung.*/", "/Enzyklopädie.*/", "/.*Diskussion.*/", "/Roman.*/", "/Newsgroup.*/", "/Tagebuch.*/", "/Sachbuch.*/")
df <- expand_grid(corpus=corpus, texttype=texttypes) %>%
mutate(vc = sprintf("%stextType=%s", corpus, texttype)) %>%
@@ -176,7 +176,9 @@
hc <- highchart() %>%
hc_add_series(type = "bar", data = df, hcaes(texttype, tokens, group=corpus)) %>%
- hc_xAxis(categories = df$texttype %>% str_replace_all("[/.*)()]", "") %>% str_replace_all("\\|", "/")) %>%
+ hc_xAxis(categories = df$texttype %>%
+ str_replace_all("Zz", "Z") %>%
+ str_replace_all("[/.*)():^\\[\\]]", "") %>% str_replace_all("\\|", "/")) %>%
hc_title(text="Texttyp")
hc
})