Add LVC DataTable to IDS example

Change-Id: Ib3ca645ed791b2589faeedb18a8e2479e2097e6d
diff --git a/examples/ids.Rmd b/examples/ids.Rmd
index 1dc5cc9..9dbbaf7 100644
--- a/examples/ids.Rmd
+++ b/examples/ids.Rmd
@@ -32,6 +32,7 @@
 library(idsThemeR)
 library(highcharter)
 library(tidyverse)
+source("https://gitlab.ids-mannheim.de/ICC/2023-07-20-ICC-ICLC10/-/raw/master/R/common.R")
 ```
 
 ## R Markdown
@@ -51,10 +52,6 @@
 Here are some notes.
 </aside>
 
-::: footer
-Custom footer text
-:::
-
 ## Slide with R Output
 
 ```{r cars, echo = TRUE}
@@ -85,5 +82,54 @@
   hc
 
 ```
+
+## Light Verb Constructions
+### with *take* (from ICC-ENG)
+
+```{r take-icc, fig.cap="Results of a co-occurrence analysis of *take* + NOUN in [ICC-ENG](https://korap.ids-mannheim.de/instance/icc), using the RKorAPClient  [@kupietz_rkorapclient_2020] package."}
+take_ca_icc <-
+  collocationAnalysis(
+    icc_con("eng"),
+    "focus({[ud/l=take]} [ud/p=NOUN])",
+    leftContextSize = 0,
+    rightContextSize = 1,
+    minOccur = 2,
+    addExamples = T
+  ) %>% head(8)
+
+take_ca_icc %>% show_table()
+```
+
+## Source Code
+### Collocation Analysis
+
+```R
+  df <- collocationAnalysis(
+    icc_con("eng"),
+    "focus({[ud/l=take]} [ud/p=NOUN])",
+    leftContextSize = 0,
+    rightContextSize = 1,
+    minOccur = 2,
+    addExamples = T
+  )
+```
+  
+## Source Code
+### Print Collocation Analysis as DataTable
+
+```R
+df %>%
+ mutate(Collocate=sprintf('<a href="%s">%s</a>', 
+  webUIRequestUrl, collocate)) %>%
+ mutate(example=str_replace(example, 
+  ".*(\\W+\\w+\\W+\\w+\\W+<mark.*/mark>.*)", "\\1")) %>%
+ mutate(example=str_replace(example, 
+  "(.*<mark.*/mark>\\W+\\w+\\W+\\w+).*", "\\1")) %>%
+ rowwise() %>%
+ select(Collocate, Example, logDice, pmi, ll) %>%
+ datatable(escape = F) %>%
+ formatRound(columns=~logDice + pmi + ll, digits=2)
+```
+
 # References