Categories
Pages
-

Research Data – Latest News & Worth Knowing

Carpentries Python Workshop

April 10th, 2025 | by
Carpentries Python Workshop

Source: Own illustration

The Software Carpentries Introduction to Python workshop on March 17 to 18, 2025, at the IT Center of the RWTH Aachen University. It was led by Jonathan Hartman from the Rhine-Ruhr Center for Scientific Data Literacy (DKZ.2R) and Catherine Gonzalez from the NFDI4Microbiota. This event was specifically designed for graduate students and researchers who are interested in learning Python.

 

A Collaborative Experience

This was more than just a workshop—it was a community-building experience. Participants were encouraged to help one another, fostering a collaborative and supportive learning environment. Using the Carpentries code of conduct, participants were encouraged to use welcoming and inclusive language, be respectful of different viewpoints and experiences to ensure the best possible experience.

 

What is Python

Python is an interpreted language, meaning you can write code directly and see the results instantly. It’s like giving instructions to your computer to perform tasks. You write code using the Python language, and the computer executes it step by step. Python is a great programming language to get an introduction to coding as it is very logical and in simplistic spoken English.

 

Assessing Participant Progress

To better understand the participants’ starting knowledge and expectations for the training, we conducted a pre-workshop survey. This helped us gauge their familiarity with Python and identify key areas where they wanted to improve. After the workshop, we followed up with a post-workshop survey to see how their answers had changed, assess their learning progress, and gather feedback on the training experience. This provided valuable insights into the effectiveness of the workshop and areas for future improvement.

For example, the chart below shows how participants’ self-reported skills and confidence levels evolved throughout the training.

 

the chart shows how participants’ self-reported skills and confidence levels evolved throughout the training

Source: Own illustration

 

We also received encouraging feedback from participants:

“I learned a lot from this workshop. All the staff were very kind and professional. I’d love to join another Python workshop under your organization. Thanks!”
“Good organization, very well-structured content with understandable examples. I liked the combination of presentations and hands-on exercises.”

“All instructors were very engaged and enthusiastic. They provided great examples of how best practices help in day-to-day coding.”
“The enthusiasm from the instructors made it easier to stay engaged in the tasks.”

 

What Participants Learned

Over the course of two days, participants explored key programming concepts through hands-on coding exercises. Some of the main topics covered included:

  • Variables – Assigning values to variables and performing calculations. Variables are names for values
  • For Loops, Accumulator Patterns, and Conditionals – For loops, automate repetitive tasks by iterating through a collection of values. Accumulator patterns, repeatedly update a variable by adding or modifying its value within a loop.  Conditionals, control the flow of a program based on certain conditions.

Example: We combined variables, loops, and conditionals to model how velocity changes over time:

The code snippet shows how we combined variables, loops and conditions to model how speed changes over time:

Source: Own illustration

 

  • Data Types and Type Conversion: Understanding different data types in Python and how to convert between them.
    • For example, data types include strings which are represented by (“Having quotes around it”); Integers (1234) and many more. You can cast a value to a data type by using str(2) or int(“2”)
  • Python’s Built-in Functions and Help: Discovering how to use Python’s built-in functions effectively and access help within the Python environment.
    • For example, common built in functions include: min(), max() which is used to find the smallest or largest value of a series of values. This works on both integers and strings
  • DataFrames with Pandas: Learning to read tabular data into DataFrames using the powerful Pandas library.
    • A DataFrame is a collection of Series; The DataFrame is the way Pandas represents a table, and Series is the data-structure Pandas use to represent a column. We looked at the GDP of various European countries by reading a .csv file with the Pandas library
  • Plotting with Matplotlib: Gaining hands-on experience in creating visualizations using the Matplotlib library.

Example: This short program uses pandas and Matplotlib to create a plot showing the correlation between GDP and life expectancy for 2007, normalizing marker size by population.

 

Source: Own illustration

 

Source: Own illustration

Throughout the workshop, participants engaged in live coding with support from Carpentries-certified instructors and workshop helpers. To complement the hands-on exercises, we also introduced broader programming concepts through short talks on:

  • The Zen of Python – A set of 19 guiding principles for writing clear and efficient code.
  • Third-Party Libraries – How external packages extend Python’s capabilities.
  • Git Version Control – Tools for tracking changes and collaborating on code.
  • Clean Code Practices – Writing readable, maintainable code using comments, docstrings, and formatting tools.

By the end of the workshop, participants had built a solid foundation in Python programming, equipping them with essential skills for research and data analysis. More importantly, they gained the confidence to continue exploring and applying these concepts in their own projects.


Responsible for the content of this article is Catherine Gonzalez.

Leave a Reply