Use Python syntax and logic to search for the data you need.
Often in research, we need to find a particular piece of data from a larger string of text or numbers. Maybe it’s a single result from a long file that gets output from a scientific instrument. Or maybe you need to find an email address from a scraped website, or 100 email addresses from 100 scraped websites. Or maybe you need to find every paragraph that contains a certain word in a novel you are studying. Whatever your use case, you can use Python to search for strings or patterns of characters. There are several ways to accomplish this task, including using built-in Python functions and the “re” package for working with regular expressions.
In this workshop, we will cover the syntax for using these tools and discuss the logic behind choosing the correct tool for each job. We will also briefly discuss the pros and cons of using LLMs vs. using Python to search through data.
Prerequisites: Participants should be familiar with Python at the level of the Python Fundamentals workshop, another introductory Python workshop, or be a self-taught Python coder.
Audience
- Faculty/Staff
- Student
- Post Docs/Docs
- Graduate Students
Contact
Leticia Vega
Email
Interest
- Academic (general)