Hands-On: A Five Day Text Mining Course for Humanists and Social Scientists in R

The article introduces our concept and experiences of teaching text mining in R to humanists and social scientists in a one week course. We teach methods to support the entire analysis workflow, from data import and conversion, basic (linguistic) preprocessing to actual analysis such as key-term extraction, co-occurrence statistics, topic models and text classification. The use of the statistical programming language R for the workshop enables participants to learn about methodical backgrounds at different depths levels, as well as to meet their own specific analysis requirements. Among other things, this is possible by relying on a vast supply of community-developed extensions for (textual) data analysis, visualization, and presentation. In detail, we introduce R Markdown tutorial sheets as a didactic core component of the course, and how they can be extended to alternative teaching formats such as a text book for self-learners. 1  With the emergence of digital humanities (DH) and computational social science (CSS), large digital text collections have become a primary source of data for empiric analyses. During the last decade, humanists and social scientists often cooperated with computer scientists in interdisciplinary pioneer projects to approach such new large-scale data sets. By opening up qualitative data analyses for “big data”,1 such projects paved the way for acceptance of these new technologies in the traditional disciplines. Text mining, defined as a set 1The term “big data” is associated with a variety of meanings. In social science and humanities contexts, it is often used as reference to data collections which significantly exceed close reading capabilities of a single researcher. of statistical and computer-linguistic methods to (semi-)automatically extract semantic structures from very large amounts of texts, started to become a major innovation in various disciplines from political science and economics to modern history (Lemke and Wiedemann, 2016). Since more and more humanist scholars became aware of the potential of computer-assisted text analysis, the demand for skills and resources to take text mining into their own hands increased. Gesis, a research infrastructure facility for the social sciences in Germany, reacted to this development by setting up a text mining course in 2014, especially targeted to humanists and social scientists. The course was integrated into the periodical education program of the institution. Participants usually are post-graduate scholars, predominantly working in the (public) science sector. The goal was not only to provide them with a theoretical overview of text mining foundations and potential applications, but to educate them to conduct analyses using their own data. Instantly, this raised the question whether the course should be based on (a variety of) publicly available standalone tools2 or if it should take the effort to introduce participants to coding. A few years back, in DH this question culminated in the famous debate of ‘more hack’ versus ‘less yack’. Pioneers of the field demanded that protagonists of DH should engage more in actual analysis and educating themselves by getting hands on data (Nowviskie, 2014). We were guided by the premise that for many humanities scholars willing to engage in DH it is actually no problem to acquire theoretical knowledge. Their major challenge is to get on track with the multiverse of potentially useful technical infrastructures. Additionally, we expected many partici2Commonly used standalone tools are AntConc (Anthony, 2014) or WordSmith (Scott, 2016). Examples for web-based infrastructures for text are Voyant tools (Sinclair and Rockwell, 2012) or the Leipzig Corpus Miner (Niekler et al., 2014).