Data Science for Research in Linguistics (LING 2020), Fall 2026
University of Pittsburgh
Instructor: Dan Villarreal, PhD
Class time: Tues/Thurs 2:30ā3:45pm
Class location: Cathedral of Learning 2818 (Linguistics Conference Room)
Office hours: Tues/Weds 4ā5pm (Danās office, CL 2806)
Textbook: See below
On this page
Overview and course objectives
Data science is a fast-growing and diverse discipline that combines programming, statistics and machine learning, scientific communication, and domain expertise. While most data scientists work in industry, a healthy understanding of data science principles and practices has started to become indispensable in many fields of linguistics research. As a result, we will approach data science in this class with an emphasis on the principles and practices that linguists need to know about how to approach dataāhow to get data into shape, how to extract a story from data, and how to communicate that story.
Students who successfully complete this course will be able to:
- Describe data science practices for data wrangling, analysis, and reporting
- Utilize modern software tools for data science as practiced in linguistics research
- Apply data science practices and software tools to a linguistics research question
Assignments
Your grade in this class will be based on the following assignments:
- To-dos (30%): For most class meetings, you will have some out-of-class tasks to prepare for the class meeting (or respond to topics weāve just discussed). These tasks may include enagaging with readings, exploring concepts on your own, and discussing classmatesā projects. I anticipate about 18 to-dos over the course of the semester. To-dos are graded for effort.
- Class participation (20%): Every student is expected to be an active participant in our class meetings and shared online spaces, as we will form a community of learners in this class. Participation is graded for effort. I am generally pretty understanding when it comes to excusing absences for reasonable circumstances (family emergencies, urgent physical or mental health needs, etc.). If you need to miss class (or arrive late/leave early), please message me on Discord with as much advance notice as possible.
- Midterm (10%): Every student should master a basic data-science toolkit that will be applicable to a wide array of potential research projects. The midterm will be take-home and open-everything. It will be a two-phase assignment. The midterm will be graded for effort.
- Final project (40%): You will carry out a data science project that pertains to a linguistics research question of your choosing, using data available āin the wildā. (This is a necessary constraint.) Ideally, this project will be related to research you intend to do for a thesis/dissertation, comps paper, etc. Along the way, you will complete several project milestones to keep you on track, culminating in a class presentation in week 15 and a polished GitHub repository due in finals week. The project will be graded for proficiency in data wrangling, analysis, and presentation.
Between to-dos, project milestones, and midterm submissions, there will always be some sort of assignment between classes. These assignments will be due by 12 noon on the day of class so I can look over your responses in preparation for class. Assignments are linked on the schedule.
This course will move fast and cover a lot of topics (including programming topics) in a short amount of time. As such, you will be expected to spend a large amount of time outside of class practicing on your own; good self-study habits are essential to successfully absorbing the course material.
However, while this course is demanding in breadth of topical familiarity, I do not expect you to necessarily achieve a breadth of topical mastery. This will be increasingly the case as the semester proceeds and we get into more-specific tools that arenāt applicable to your own research. Given the massive range of data science tools out there, learning to prioritize and hone your skills selectively is an essential competency you will need to develop.
Percentage grades will be converted to letter grades using the usual grading scale: A+ ā„ 97 > A ā„ 94 > Aā, etc.
Requirements
- Prerequisite: LING 1810/2010 (Stats for Linguistics) or the equivalent.
- Hardware: The software applications below should install and run from your own personal laptop, which you are expected to bring to every class meeting.
- Your laptop should run one of these OSs: Mac OS X (10.6 or later), Windows (10 or 11), and Linux (any distribution).
- Mobile and cloud-based OSs are not supportedātablets and Chromebooks are not suitable platforms for this class.
- Make sure youāve got ample space on your hard drive to download software and data. You should ideally have at least 30 Gb free and at least 25% of disk space after downloading the required software below
- Your laptop should run one of these OSs: Mac OS X (10.6 or later), Windows (10 or 11), and Linux (any distribution).
- Software: We will primarily be working in the statistical programming language R, in particular the tidyverse dialect, through the free RStudio IDE. Please download the following:
- Textbook: In the first part of the semester we will be leaning heavily on the free textbook R for data science, 2nd edition (original by Hadley Wickham, Mine Ćetinkaya-Rundel, & Garrett Grolemund, forked and lightly edited by Dan). If youād like a physical copy of the book, you can order it on Bookshop.org.
Please update your R to version 4.6.1 so you get the latest and greatest features!
If youāve used RStudio with a previous version of R, youāll also need to point RStudio to the latest version; go to Tools > Global Options and change the directory under āR Versionā.
You donāt need to install any packages right now; the textbook will include instructions on which packages to install when. However, if you want to port over your installed packages from your old version of R, do the following:
- In your old version of R, run
dput(rownames(installed.packages()))in the console- Copy the result to your clipboard
- Update R
- In R 4.6.1, run
install.packages(PASTE HERE).
Clever you, finding an HTML easter egg! You might have noticed the green bird on the cover of R for data science, which is also our courseās avatar. Thatās a kÄkÄpÅ, a critically endangered New Zealand parrot; as of the start of the semester, there are only 235 kÄkÄpÅ left. Please consider making a donation to New Zealandās KÄkÄpÅ RecoveryāIāll match any student donations.
Communication
Email is bad. All communication will take place through our classās Discord server. Please join the server via this invite link. Our Discord server is your means for asking questions about course content or logistics, and itās where Iāll post important info about the class. You are responsible for making sure you are able to receive and read Discord messages in a timely fashion.
Questions about course content or policies should be posted to the #q-and-a channel so the entire class can benefit from your question. For sensitive information (e.g., family emergencies), send me a direct message (DM).
You can post to Discord at any time, and Iāll respond as soon as Iām able. (I donāt check Discord at night or on weekends, but feel free to post anyway!)
If you already have a Discord account but you donāt want to link it to the class Discord server, you can create a separate Discord account through the Account Switcher on the desktop app. Click your avatar image on the bottom-left, then Switch Accounts, then Add an account. Unfortunately, the only way to switch accounts on the Discord mobile app is logging out and logging back in.
Course policies
The openness principle, your work, and privacy
Data science, as a young interdisciplinary field, has fully embraced the principle of open, transparent and collaborative mode of scientific inquiry. The overwhelming popularity of GitHub speaks volumes to this ethos. In this class, we too will adopt the principle of openness in most everything we do. However, I recognize that the course is foremost a learning platform and therefore there exist certain expectations of privacy in the work students submit. In order to balance the two considerations, the course will adopt the following tiered privacy policy:
- Fully public: Individual studentsā projects will be completely open: projects will be developed and submitted via a GitHub public repository in our class GitHub organization, where they are open to the world to view. Some To-dos may also fall under this designation.
- Private: Our class Canvas site will be utilized for the aspects of course work that should remain strictly private between a student and the instructor. Those include posting of grades and feedback on student performance.
Course materials will largely follow the same format. Most materials will be available through our class GitHub organization, and lecture recordings will be available on Canvas.
Late work
Assignments (To-dos and project milestones) are due by 12 noon the day of class. The nature of this course is that much of our work in class meetings will build directly on these assignments, so punctuality is a must.
- Late To-dos will incur a 50% penalty if submitted up to 24 hours late, with no To-dos accepted after that. Remember that To-dos are graded for effort, so as long as you start early enough, you should have no problem getting full credit. Still, things happen, so I will drop your lowest To-do score (i.e., you have one free lateness or free miss).
- Late project milestones will incur a 20% penalty if submitted up to 24 hours late, with an additional 10% penalty for each late day thereafter.
Collaboration on assignments
If done properly, working together on assignments leads to better learning outcomes for all parties involved. Improper collaboration, however, negatively affects learning. In this class, group work is allowed (and even encouraged!)āprovided that the following conditions are met:
- Equal contribution: One studentās contribution must not exceed 150% of anotherās.
- Individual work before a study group: If you work with other students out of class, do not show up to the study group without having worked on the assignment on your own beforehand.
- Individual work after a study group: Do not write up your assignments while working in group, which leads to copying otherās answers. Always finish up your answers by yourself afterwards, using your own words.
- Do NOT pass files: Do not, under any circumstances, send or receive script files prior to submitting your work.
- Disclosure: You must disclose any classmates you worked with.
- Not on the midterm: Your initial answers to the midterm must be your own work.
See also the generative AI policy below.
Academic integrity
Students in this course will be expected to comply with the University of Pittsburghās Policy on Academic Integrity. Any student suspected of violating this obligation for any reason during the semester will be required to participate in the procedural process, initiated at the instructor level, as outlined in the University Guidelines on Academic Integrity. To learn more about Academic Integrity, visit the Academic Integrity Guide for an overview of the topic.
For hands-on practice, complete the Academic Integrity Modules.
Generative AI
This classās assignments have been designed to help you develop as a data scientist, including as a coder. But in the year 2026, what it means to code is changing. As a society, we are all learning about how generative AI coding tools (e.g., ChatGPT) can be used productively, effectively, and ethically to inform our coding process. As such, in this class, the use of generative AI is allowed within specific contexts and only if such use is properly acknowledged. Specifically:
- Generative AI is permitted onlyā¦
- for longer assignments (midterm, project), and
- if you include an āAcknowledgement of AI Useā statement that:
- specifies which technology was used (ChatGPT, GPT-3, etc.), and on what date
- include a permalink to the relevant chat (instructions for ChatGPT, Google Gemini), so instructors can understand how the information was generated
- explain how the output was used in your works
You do not have to provide a formal in-text citation for AI systems, and you only need to include an āAcknowledgement of AI Useā if you used generative AI.
The use of AI outside of contexts where the instructor specifies its use, or failure to acknowledge any use of AI technologies in your work, will be considered an academic integrity violation and addressed according to Pittās Academic Integrity Policy. You are the author of your work for the course and authorship means you take responsibility for your words and code, regardless of which tools you use.
This policy was informed by Pittās Writing Institute. The landscape around generative AI is complex and ever-changing, so please donāt hesitate to ask if you have any questions about this policy.
Disability resources
The University of Pittsburgh is committed to inclusive and accessible education experiences for all students. If you have a disability for which you are, or may be, requesting an accommodation, you are encouraged to contact Disability Resources and Services (DRS), 140 William Pitt Union, (412) 648-7890, drsrecep@pitt.edu, as early as possible in the term. DRS will engage in a review process with you to determine eligibility and reasonable accommodations. If you are already registered with DRS, please complete the necessary steps on the DRS Student Portal to utilize your accommodations this term.
Note from Dan: Many disabilities are invisible, so do not hesitate to contact DRS if you have questions.
Accessibility
The University of Pittsburgh is committed to providing equal access by making all electronic and information technology accessible to all users. This includes instructional materials and the Canvas LMS platform.
- If you experience accessibility issues regarding course-specific material, please reach out to the instructor.
- If you experience a University-wide or other large-scale accessibility issue, please report the digital accessibility barrier to the Digital Accessibility Coordinator.
- If you are registered with Disability Resources and Services and experience issues with approved accommodations, you may contact Disability Resources and Services (DRS), 140 William Pitt Union, (412) 648-7890, drsrecep@pitt.edu
Religious Observances
The University of Pittsburgh strives to foster a supportive environment and to respect the beliefs and values of all community members. Accordingly, recognizing that certain students may observe religious holidays (activities observed by a religious group of which a student is a member) and cultural practices that conflict with scheduled class activities, instructors will work with students to try to make reasonable accommodations in the event of such a conflict.
At the beginning of the semester, you should review the course requirements to identify foreseeable conflicts with assignments, exams, or other required attendance. If you identify a conflict, please contact your instructor (or your course coordinator/s), ideally within the first two weeks of the first class meeting, to allow time to discuss and attempt to make fair and reasonable adjustments to the schedule and/or tasks.
Copyright Notice
These materials may be protected by copyright. United States copyright law, 17 USC section 101, et seq., in addition to University policy and procedures, prohibit unauthorized duplication or retransmission of course materials.
See Library of Congress Copyright Office and the University Copyright Policy.
Statement on Classroom Recording
To ensure the free and open discussion of ideas, students may not record classroom lectures, discussion and/or activities without the advance written permission of the instructor, and any such recording properly approved in advance can be used solely for the studentās own private use.
Your well-being matters
Your well-being plays an important role in your ability to learn, engage, and succeed academically, and seeking support when needed is a normal and healthy part of the academic experience. Visit the Student Wellness resources site to learn more about available resources, schedule appointments, and connect with support services. Mental health support is also available 24/7 through the University Counseling Center at 412-648-7930. You can also call or text 988 to reach the Suicide & Crisis Lifeline, or text HOME to 741741 to connect with the Crisis Text Line. If there is a risk of harm to yourself or others, contact University of Pittsburgh Police at 412-624-2121 or dial 911.
Please take care of yourself and your fellow students.
The only constant is change.
This syllabus is subject to change, because data science tools are always changing and every set of students is a little different. I will be tweaking the courseās content and logistics to best serve our particular group. When (not if!) the syllabus changes, Iāll communicate as much as I can as soon as I can.
Class schedule
In the Reading column:
- Chapter numbers on their own refer to R for data science
- TMwR + chapter numbers refer to Text mining with R
| Wk | Date | Unit | Topic | Reading | Due (before class @ 12n) To-do Project milestone |
|---|---|---|---|---|---|
| 1 | Aug 25 | Intro | Intro, Git | ||
| Aug 27 | Git, GitHub | Intro, 2 | #1 | ||
| 2 | Sep 1 | Data visualization with ggplot2 | 1, 6 | #2 | |
| Sep 3 | Quarto | 28 | #3 | ||
| 3 | Sep 8 | Data wrangling | Data wrangling with dplyr | 3 | #4 |
| Sep 10 | Tidy data with tidyr | 5 | #5 | ||
| 4 | Sep 15 | Relational data (the dplyr family of join functions) | 19 | #6 | |
| Sep 17 | Data import & export with readr | 7 | |||
| 5 | Sep 22 | Data structures | 23 | ||
| Sep 24 | Iteration with purrr | 26 | |||
| 6 | Sep 29 | Strings with stringr | 14 | ||
| Oct 1 | Regular expressions Midterm released | 15 | |||
| 7 | Oct 6 | Intermission | Decolonizing open methods | Villarreal and Collister 2024 | |
| Oct 8 | Review project plans; auto-coding fairness | Villarreal 2024 | |||
| 8 | Oct 13 | Large language models | Bender et al. 2021 | ||
| Oct 15 | Midterm check-in | ||||
| 9 | Oct 20 | Text data | Tidy text format with tidytext | TMwR 1 | |
| Oct 22 | Word and document frequency, lemmatization | TMwR 3 | |||
| 10 | Oct 27 | Web scraping | HTML format, rvest basics | 24 | |
| Oct 29 | Web-scraping use case | ||||
| 11 | Nov 3 | Machine learning | ML concepts | ||
| Nov 5 | ML algorithms | ||||
| 12 | Nov 10 | Flex time | TBD based on final projects | ||
| Nov 12 | TBD based on final projects | ||||
| 13 | Nov 17 | TBD based on final projects | |||
| Nov 19 | TBD based on final projects | ||||
| 14 | Nov 24 | No class (Thanksgiving break) | š¦š¦š¦š¦š¦š¦š¦š¦š¦š¦š¦š¦š¦š¦š¦š¦ | ||
| Nov 26 | š¦š¦š¦š¦š¦š¦š¦š¦š¦š¦š¦š¦š¦š¦š¦š¦ | ||||
| 15 | Dec 1 | Project presentations & wrap-up | Presentations | ||
| Dec 3 | Review & reflection |