Install the app

Install this application on your home screen for quick and easy access when you’re on the go.

Just tap Share then “Add to Home Screen”


Install the app

Install this application on your home screen for quick and easy access when you’re on the go.

Just tap Share then “Add to Home Screen”


You don't have anything in your basket.

Your subscription could not be saved. Please try again.
Your subscription to the ECPR Methods School offers and updates newsletter has been successful.

Discover ECPR's Latest Methods Course Offerings

We use Brevo as our email marketing platform. By clicking below to submit this form, you acknowledge that the information you provided will be transferred to Brevo for processing in accordance with their terms of use.


Quantitative Text Analysis and Machine Learning using R

Member rate £492.50
Non-Member rate £985.00

Save £45 Loyalty discount applied automatically*
Save 5% on each additional course booked

*If you attended our Methods School in July/August 2023 or February 2024.

Course Dates and Times

Date: Monday 29 July – Friday 2 August 2024
Time: 14:00 – 17:00 CEST

Zachary Greene

University of Strathclyde

This course offers  you with an immersive online learning environment that employs state-of-the-art pedagogical tools. With a maximum of 16 participants, our teaching team can provide personalised attention to each individual, catering to their specific needs. The course is designed for a demanding audience, including researchers, professional analysts, and advanced students.

Purpose of the course

The abundance of textual data in modern times provides a rich source of information on social and political behavior. As a result, social scientists have increasingly turned to computational or computer-assisted methods to extract insights from this data. This course is designed to equip you with the foundational knowledge and skills required to manage and analyse textual data using R.

Upon completion of the course, you will:

  • develop a conceptual understanding of basic approaches to natural language processing;
  • gain familiarity with common quantitative text analysis techniques used in political science literature and be able to interpret the results; and
  • learn how to implement the most widely used methods employed by social scientists.

The course covers the following topics:

  • The fundamentals of quantitative text analysis using machine learning.
  • Estimation of dictionary, sentiment, topic, and scaling models.
  • Methods for text classification using supervised machine learning.
  • Word embeddings and textual representation models.
ECTS Credits

3 ECTS credits awarded for engaging fully in class activities.
1 additional ECTS credit awarded for completing a post-course assignment.

Instructor Bio

Zachary Greene is a Reader at the University of Strathclyde. His research interests include quantitative text analysis and machine learning approaches to studying political parties, parliaments and elections.

His work has been published in journals including, the British Journal of Political Science, European Journal of Political Research, Journal of European Public Policy, Party Politics and Electoral Studies. You can find more information on Dr Greene’s research, teaching and ongoing projects at


Thanks to the advancements in personal computing and the internet, humans now produce an overwhelming amount of textual data. While social scientists have traditionally employed quantitative and qualitative content analysis techniques to read and annotate texts manually, the recent breakthroughs in computational approaches to natural language processing have made it possible for researchers to manage and analyse much larger datasets. With these new tools, social scientists can now study a range of topics that were previously inaccessible due to resource constraints, such as organisational ideology, media bias and sentiment, policy change, social media, and information diffusion.

The goal of this course is to equip students with the knowledge and skills to harness computational approaches to analyse text data. By the end of the course, you will:

  • understand the conceptual framework and data management techniques necessary for analysing text data as data, including the fundamentals of natural language processing using machine learning;
  • be familiar with common computational approaches to text analysis that are widely used in political and social sciences;
  • be introduced to advanced methods for managing and analysing text data using embeddings approaches.

Overall, the course aims to provide you with the tools and techniques you need to develop projects that utilise computational approaches to text analysis.

Key topics covered

Day 1: Introduction to Quantitative Text Analysis using R

This session will introduce you to the theoretical assumptions and key concepts for performing quantitative text analysis, and will showcase several features of the Quanteda package in R. Through examples, the session will illustrate how researchers can use both quantitative and qualitative analysis to gain insights from textual data.

Day 2: Dictionaries and Sentiment Analysis

Keyword searches and dictionary-based approaches offer a straightforward method for analysing most texts. One practical application is the study of sentiment, as text often contains clues to the writer's tone, emotion, or attitude. In this session, we will provide an overview of commonly used techniques for extracting this information in political contexts.

Day 3: Scaling and Topic Models

Scholars interested in identifying differences between texts based on underlying concepts such as ideology or institutional origin often turn to scaling and topic models. This session will introduce you to Wordfish and Wordscores, two common scaling models, and provide an overview of approaches for validating their estimates. The session will also cover topic models, which can reveal a set of topics within documents with little prior knowledge of their contents. Specifically, the classical LDA model and the Structural Topic Model will be discussed. Finally, the session will explore various applications of these tools.

Day 4: Introduction to Classification and Supervised Machine Learning

Supervised approaches to text classification involve using existing annotated text to predict the content of uncoded texts. These methods have enabled major advancements in artificial intelligence, and are widely used by organisations like Google and Facebook for analysing massive corpora of text. In addition, these approaches are highly relevant for measuring political concepts. This session will cover the logic of training and evaluating classification models, followed by exploration of specific applications in political science.

Classification based approaches can be used to predict values of interest such as the issues and positions, sentiment or emotions, and other dimensions of text that researchers have traditionally used content analysis to derive.

Day 5: Advanced Topics in Quantitative Text Analysis

This session will cover a set of advanced topics in quantitative text analysis including word embeddings and textual representations, data management, hypothesis testing and data visualisation.

How the course will work online

This course is structured around lectures and labs, with each session comprising a 1.5-hour lecture followed by a 1.5-hour lab, delivered through Zoom. The lectures will provide an overview of relevant concepts and statistical foundations necessary to apply machine learning approaches to textual data, as well as highlight recent applications of these methods in the social sciences. The lab sessions will allow students to gain hands-on experience by applying these methods to political and social science data using common R packages, including the quanteda suite.

The instructor will also conduct live Q&A sessions and offer designated office hours for one-to-one consultations.

It is important to note that this course serves as an introduction to these topics. While you will gain a solid understanding of the subject and practical experience, the course will not cover advanced topics in depth.

Prerequisite Knowledge

Prior knowledge of R and quantitative methods is required for this class. In the live sessions, you will receive hands-on instruction on performing quantitative text analysis and machine learning using R.

Learning commitment

As a participant in this course, you will engage in a variety of learning activities designed to deepen your understanding and mastery of the subject matter. While the cornerstone of your learning experience will be the daily live teaching sessions, which total three hours each day across the five days of the course, your learning commitment extends beyond these sessions.

Upon payment and registration for the course, you will gain access to our Learning Management System (LMS) approximately two weeks before the course start date. Here, you will have access to course materials such as pre-course readings. The time commitment required to familiarise yourself with the content and complete any pre-course tasks is estimated to be approximately 20 hours per week leading up to the start date.

During the course week, you are expected to dedicate approximately two-three hours per day to prepare and work on assignments.

Each course offers the opportunity to be awarded three ECTS credits. Should you wish to earn a 4th credit, you will need to complete a post-course assignment, which will involve approximately 25 hours of work.

This comprehensive approach ensures that you not only attend the live sessions but also engage deeply with the course material, participate actively, and complete assessments to solidify your learning.


This course description may be subject to subsequent adaptations (e.g. taking into account new developments in the field, participant demands, group size, etc.). Registered participants will be informed at the time of change.

By registering for this course, you confirm that you possess the knowledge required to follow it. The instructor will not teach these prerequisite items. If in doubt, please contact us before registering.