Teaching Python for Data Science: Collaborative
development of a modular & interactive curriculum
Marlena Duda∗1 , Kelly L. Sovacool†1 , Negar Farzaneh1, 11 , Vy Kim
Nguyen1, 8 , Sarah E. Haynes6 , Hayley Falk1 , Katherine L. Furman3, 4 ,
Logan A. Walker5, 1 , Rucheng Diao1 , Morgan Oneka1 , Audrey C.
Drotos10 , Alana Woloshin7 , Gabrielle A. Dotson1 , April Kriebel1 , Lucy
Meng9 , Stephanie N. Thiede2 , Zena Lapp‡1 , and Brooke N. Wolford§1
1 Department of Computational Medicine & Bioinformatics, University of Michigan 2 Department
of Microbiology & Immunology, University of Michigan 3 Neuroscience Graduate Program,
University of Michigan 4 Michigan Neuroscience Institute, University of Michigan 5 Biophysics
Graduate Program, University of Michigan 6 Department of Pathology, University of Michigan 7
School of Information, University of Michigan 8 Department of Environmental Health Sciences,
University of Michigan 9 Department of Electrical Engineering & Computer Sciences, University of
California, Berkeley 10 Kresge Hearing Research Institute, Department of Otolaryngology–Head and
Neck Surgery, University of Michigan 11 Michigan Center for Integrative Research in Critical Care,
University of Michigan
DOI: 10.21105/jose.00138
Software
• Review
Summary
• Repository
• Archive
We are bioinformatics trainees at the University of Michigan who started a local chapter
Submitted: 16 June 2021 of Girls Who Code to provide a fun and supportive environment for high school women
Published: 17 December 2021 to learn the power of coding. Our goal was to cover basic coding topics and data sci-
License ence concepts through live coding and hands-on practice. However, we could not find
Authors of papers retain copy- a resource that exactly met our needs. Therefore, over the past three years, we have
right and release the work under developed a curriculum and instructional format using Jupyter notebooks to effectively
a Creative Commons Attribution teach introductory Python for data science. This method, inspired by The Carpentries
4.0 International License (CC BY organization, uses bite-sized lessons followed by independent practice time to reinforce
4.0). coding concepts, and culminates in a data science capstone project using real-world data.
We believe our open curriculum is a valuable resource to the wider education community
and hope that educators will use and improve our lessons, practice problems, and teaching
best practices. Anyone can contribute to our Open Educational Resources on GitHub.
Statement of Need
As women bioinformatics trainees at the University of Michigan (U-M), we experience
the gender gap in our field first-hand. During the 1974-1975 academic year, women
achieved 18.9% of total Bachelor’s degrees in computer and information sciences in the
US (National Center for Education Statistics, 2012). By 1983-1984 this peaked at 37.1%,
but fell to 17.6% by 2010-2011. We also see this national trend in the training of the next
generation of Bioinformaticians at Michigan Medicine. Since accepting its first students
∗ firstauthor
† first
author
‡ corresponding author
§ corresponding author
Duda et al., (2021). Teaching Python for Data Science: Collaborative development of a modular & interactive curriculum. Journal of Open 1
Source Education, 4(46), 138. [Link]
in 2001, the U-M Bioinformatics Graduate Program has graduated 66 male and 22 female
doctorates as of 2019. This disparity begins at the applicant level; during 2016-2019 the
average percentage of females applying directly to the Bioinformatics PhD program was
35.2%, and the average percentage of female applicants listing Bioinformatics as first or
second choice in the Program in Biomedical Sciences, U-M’s biomedical PhD umbrella
program was 41%.
Previous research on women’s educational experiences in science, technology, engineer-
ing, and mathematics (STEM) have produced various explanations for persistent gender
disparities (Benbow & Vivyan, 2016). One explanation is that women often experience
stereotype threats that negatively influence their math and science performance and deter
them from pursuing STEM as a career (Hill et al., 2010). The majority of our organiza-
tion’s founding graduate students (all women) began coding in our undergraduate careers
or later. We wanted to provide a safe environment for local high school women to develop
confidence in themselves and their computational skills before college, and be exposed to
successful women role models in STEM to counter negative stereotypes.
Girls Who Code, a national organization whose mission is to close the gender gap in
technology (Saujani, 2015), was founded in 2012. Because of our personal experiences
and the paucity of women in our field (Bonham & Stefan, 2017; National Center for
Education Statistics, 2012), we began a Girls Who Code student organization at the
University of Michigan in 2017. For the past four academic years we have registered
annually as a recognized Girls Who Code Club because the national organization provides
name recognition, curriculum resources, guidance for a Capstone Impact Project, and a
framework for launching a coding club. Participants in the Club attend weekly meetings
at the University of Michigan (when the club is run in person rather than virtually), and
are thus largely high school women from the Ann Arbor area. In 2019 we launched our
own summer program, the Data Science Summer Experience. When held in person, the
Summer Experience is hosted in Detroit to provide the opportunity for high school women
outside of Ann Arbor to learn coding skills in an inclusive environment.
The national Girls Who Code organization provides a curriculum that teaches website
and application development through programming languages like HTML and Java; how-
ever, our biomedical science graduate students generally have limited experience with
these languages and with web development. In contrast, many of us have extensive expe-
rience performing data science using the Python programming language. Data Scientist
was rated the #1 job in America by Glassdoor in 2016-2019, #3 in 2020, and #2 in
2021 (Stansell, 2019). Furthermore, Python is the most popular programming language
according to the PYPL PopularitY of Programming Language Index (PYPL PopularitY
of Programming Language Index, n.d.). Therefore, we believe career exploration in data
science using the Python programming language will optimally prepare our learners for
careers that provide financial stability and upward economic mobility. By leveraging the
data science expertise of our Club facilitators (hereafter termed instructors), we created a
specialized curriculum focused on computational data science in the Python programming
language.
Girls Who Code encourages participants to learn programming skills while working on an
Impact Project website or application throughout the Club (Girls Who Code HQ, 2021).
We created an open source Data Science curriculum that teaches the requisite Python
and statistics skills to complete a Capstone Project, where learners explore, analyze, and
present a data set of their choosing. Using this curriculum, we employ participatory live
coding, where learners type and run code along with the instructor in real time. Using
paired activities, our curriculum follows the “I do, we do, you do” didactic paradigm
(Fisher & Frey, 2013). We provide open source resources for both in-person and virtual
versions of our curriculum, including videos corresponding to each lesson. While we
developed this curriculum for our Girls Who Code Club and Summer Experience, we
believe that it can be widely used for teaching introductory coding for data science.
Duda et al., (2021). Teaching Python for Data Science: Collaborative development of a modular & interactive curriculum. Journal of Open 2
Source Education, 4(46), 138. [Link]
Collaborative Curriculum Development
We assembled a team of volunteers involved in our club to develop a custom curriculum
to teach introductory Python for data science. We chose the content based on what our
learners would need to learn to complete a small data analysis project and communicate
their findings to their peers. We divided the content by topic into Jupyter notebooks
for each lesson, with each lesson taking approximately 15-20 minutes to teach via live
coding. Every lesson has a corresponding practice notebook with additional exercises on
the same content taught in the lesson, but using different data or variables. We used
a similar development workflow as the U-M Carpentries curriculum (Lapp et al., 2021).
Briefly, we hosted the curriculum notebooks in a public GitHub repository to facilitate
collaborative development and peer review using pull requests. In the initial curriculum
drafting phase, developers were assigned lesson and practice notebooks to write. Once
the draft of a lesson was completed, the writer opened a pull request and asked for review
from a different developer. The reviewer then provided feedback and approved the pull
request to be merged into the main branch after the writer made any requested changes.
This way, more than one person viewed each notebook before it could be incorporated into
the public curriculum, which reduced mistakes and ensured higher quality content. While
teaching from the curriculum at the first Data Science Summer Experience, instructors
took notes on their experience and made revisions afterward. Maintainers continue to
monitor the repository and resolve issues as they arise.
Following the onset of the COVID-19 pandemic, we quickly pivoted our club to a virtual
format. In preparation for the 2020 Summer Experience, we switched to a flipped class-
room style following feedback from our club participants that it was too difficult to follow
along live coding via Zoom (see Instructional Design).
Curriculum
Our curriculum was designed for high school students with no prior coding experience
who are interested in learning Python programming for data science. However, this course
material would be useful for anyone interested in teaching or learning basic programming
for data analysis.
Learning Objectives
The learning objectives of this curriculum are:
1. Write code in Python with correct syntax and following best practices.
2. Implement fundamental programming concepts when presented with a program-
matic problem set.
3. Apply data analysis to real world data to answer scientific questions.
4. Create informative summary statistics and data visualizations in Python.
These skills provide a solid foundation for basic data analysis in Python. Participation in
our program exposes learners to the many ways coding and data science can be impactful
across many disciplines.
Course Content
Our curriculum design consists of 27 lessons broken up into 5 modules that cover Jupyter
notebook setup, Python coding fundamentals, use of essential data science packages in-
Duda et al., (2021). Teaching Python for Data Science: Collaborative development of a modular & interactive curriculum. Journal of Open 3
Source Education, 4(46), 138. [Link]
cluding pandas and numpy, basic statistical analyses, and plotting using seaborn and
matplotlib (Figure 1) (Harris et al., 2020; Hunter, 2007; Waskom, 2021). Each lesson
consists of a lesson notebook and a practice notebook containing similar exercises for the
learner to complete on their own following the lesson.
Figure 1: Our lesson modules. All Jupyter notebooks are available on GitHub ([Link]
GWC-DCMB/curriculum-notebooks).
Each lesson builds on those before it, beginning with relevant content reminders from
the previous lessons and ending with a concise summary of the skills presented within.
As they progress through the curriculum, the learners begin simultaneously working on
a data science project using a real world dataset of their choosing. While more time
is dedicated to lessons early in the program, the formal curriculum tapers off until the
learners are solely applying their skills to the data science project. Through this Capstone
Project, learners gain practical experience with each skill as they learn it in the lessons;
including importing and cleaning data, data visualization, and basic statistical analyses.
Instructional Design
We modeled our instructional design in the style of Software Carpentry (Wilson, 2016).
1. Each lesson begins with a recapping of the relevant core skills presented in the
previous lessons.
2. All lessons are designed to be taught via 15-minute live-coding sessions. This method
is used by The Carpentries and is demonstrated to be an effective method that
engages learners (Nederbragt et al., 2020; Wilson, 2016) since learners must actively
engage with the material and deal with errors and bugs as they arise.
3. Each lesson ends with a summary of core skills presented within the material.
4. Each short lesson is also accompanied by a subsequent 10-minute independent prac-
tice, providing further opportunity for practical experience implementing the coding
skill at hand and testing learners’ understanding of the content.
To better facilitate virtual instruction during the COVID-19 pandemic, we switched to a
flipped classroom. Prior to meeting, learners watch videos of instructors explaining the
Duda et al., (2021). Teaching Python for Data Science: Collaborative development of a modular & interactive curriculum. Journal of Open 4
Source Education, 4(46), 138. [Link]
material through “live” coding and code along in the lesson notebook with while watching
the video. Each video shows the Jupyter notebook alongside the instructor themselves
teaching. Learners then complete a practice notebook corresponding to the lesson. During
the virtual meeting time, instructors answer questions and review the core concepts in
the practice exercises. This virtual format is especially beneficial because it 1) allows
learners to learn at their own pace, and 2) enables dissemination of our curriculum to a
wider audience interested in learning introductory Python programming for data science.
For both in-person and virtual instruction, once learners have completed the Funda-
mentals module and reach the Data Science Essentials module they begin simultaneous
work on their data science projects. Projects are completed in a pair programming style,
where partners take turns assuming the “driver” (i.e. the typer) and “navigator” (i.e. the
helper) roles (Hannay et al., 2009). Switching off in this way helps both partners assume
equal responsibility for the project workload, but more importantly it enables improved
knowledge transfer through peer-to-peer learning. The culmination of the project is a
presentation to peers, instructors, and family members. Through this process learners
gain hands-on experience coding, cleaning data, performing statistical analyses, creating
informative data visualizations, and communicating their results to others.
In addition to our coding curriculum, another key component of our programming is
hosting women guest speakers from diverse fields across academia and industry. Our
guest speakers come to discuss the journey they have taken to their career paths as well
as how they utilize programming and data science in their jobs. These varied perspec-
tives are extremely valuable to our learners as they provide several practical examples of
programming careers in the real world, and expose them to successful women in STEM.
Experience of Use
We have used this curriculum to teach the Data Science Summer Experience and Girls
Who Code Club in person in 2019 and virtually in 2020-2021. For both in-person and vir-
tual instances, we had several instructors present at each session to answer questions and
help learners debug. Furthermore, one or two instructors were assigned to each project
group to help learners define data analysis questions, develop and execute a data anal-
ysis plan, visualize and communicate their findings, and troubleshoot coding problems.
Projects have ranged from investigating exoplanets to studying the genomics of psoriasis.
We credit the success of our curriculum not only to the skill of the instructors, but also
to the way we organized and executed the lessons and project:
1. The instructors and learners used Google Colaboratory (Colab) to write and execute
code in Jupyter notebooks. We chose this option because learners do not have
to install any programs to use Google Colab and can easily open and edit the
Jupyter notebooks from GitHub. When meeting in person, most learners use Google
Chromebooks which have limited programming capabilities, but easy use of a web
browser.
2. Assigning instructors to groups allowed learners to build a more personal connection
with their instructors, making them feel more comfortable asking questions.
3. Group projects were performed using pair programming to allow learners to collab-
orate and learn from each other.
4. We used the “sticky note” system from The Carpentries by which learners can ask
for help by putting up a colored sticky note (or a Zoom emoji in the case of virtual
meetings) (Becker, 2016).
5. We exposed the learners to different aspects of data science by bringing in women
guest speakers from academics and industry. This allowed them to better put what
they were learning into context, think about how they might use the skills they
Duda et al., (2021). Teaching Python for Data Science: Collaborative development of a modular & interactive curriculum. Journal of Open 5
Source Education, 4(46), 138. [Link]
were learning in potential future careers, and exposed them to successful women in
STEM.
Learner experiences
We surveyed learners anonymously after each Club and Summer Experience and found
that most felt that their skills in Python programming, problem solving, critical thinking,
and collaboration had improved (Figure 2). Furthermore, on a 10 question skills assess-
ment during the 2019-2020 instance of the Club, the average increase in correct answers
between the first meeting and the last meeting was 4.2 with a standard deviation of 2.8
(N=5 respondents). We also surveyed Club and Summer Experience alumni and found
that 75% (N=20) want to pursue a STEM career. 62% (N=21) are still coding. On a
5-point scale from ‘Strongly Disagree’ to ‘Strongly Agree,’ the average answer for ‘My par-
ticipation in GWC impacted my career aspirations’ is 4 (s.d.=0.9), with 4.5 (s.d.=0.6) for
‘Participating in GWC made me feel more confident in analyzing data’ and 3.9 (s.d.=1)
for ‘Participating in GWC made me more confident in myself.’
Figure 2: Post-survey responses. Learners were asked if they felt that their skills in Python pro-
gramming, problem solving, critical thinking, and collaboration had improved.
Overwhelmingly, learners’ favorite parts of the program are the guest speakers and the
project. These aspects of our curriculum expose them to new fields and allow them to
apply their newfound coding skills to asking an interesting question. A 2021 Club learner
shared, “I plan to go to college for Computer Science and get a robotics minor when
my college offers it. GWC has inspired me to consider pursuing a Masters or PhD in
CS as well as take some electives in Data Science.” Five of our 86 alumni have gone
on to perform research with U-M faculty members, with one presenting her work at an
international conference. In fact, about a third of participants claim that they are now
more interested in pursuing a career in computer or data science compared to before their
Girls Who Code experience.
Duda et al., (2021). Teaching Python for Data Science: Collaborative development of a modular & interactive curriculum. Journal of Open 6
Source Education, 4(46), 138. [Link]
Acknowledgements
We would like to acknowledge our faculty co-sponsors Maureen Sartor & Cristina Mitrea.
We appreciate the continued support of U-M DCMB staff and faculty including Julia
Eussen, Mary Freer, Linda Peasley, Jane Wiesner, Brian Athey, and Margit Burmeister.
We are grateful for the resources provided by the national Girls Who Code organization.
Our programming is made possible by the dedication of past and present Executive Com-
mittee members, Club and Summer Experience Facilitators, and Capstone Project men-
tors including Shweta Ramdas, Alex Weber, Arushi Varshney, Sophie Hoffman, Hojae
Lee, Ruma Deb, Saige Rutherford, Michelle McNulty, Bailey Peck, Chloe Whicker, Car-
olina Rojas Ramirez, Verity Sturm, Zoe Drasner, Sarah Latto, Emily Roberts, Angel
Chu, Vivek Rai, Hillary Miller, Ashton Baker, Murchtricia Jones, Lauren Jepsen, Aubrey
Annis, Awanti Sambarey, Mengtong Hu, Maribel Okiye, Yingxiao Zhang, and Neslihan
Bisgin.
We are grateful for the funding, assistance, and other support provided to our student or-
ganization from the following sponsors: the U-M Department of Computational Medicine
and Bioinformatics, the U-M Department of Biostatistics, the U-M Department of Statis-
tics, the U-M Office of Graduate and Postdoctoral Studies, the U-M Endowment in Basic
Sciences, the U-M Detroit Center, the U-M Life Sciences Institute, the U-M Office of
Research, the Michigan Council of Women in Technology Foundation, DELL Technolo-
gies, Cisco Systems, Zingerman’s Delicatessen, the Girls Who Code Support Fund, and
anonymous donations from Giving Blue Day 2019.
We also thank the learners who have participated in our Club and Summer Experience
events.
Funding
MD, ACD, ZL, and BNW received support from the National Science Foundation Gradu-
ate Research Fellowship Program under Grant No. DGE 1256260. Any opinions, findings,
and conclusions or recommendations expressed in this material are those of the authors
and do not necessarily reflect the views of the National Science Foundation.
MD, KLS, NF, and VKN received support from the NIH Training Program in Bioinfor-
matics (T32 GM070449). NF was supported by the National Institute of Health (NIH)
Ruth L. Kirschstein National Research Service Award (NRSA) Individual Predoctoral Fel-
lowship Program (F31 LM012946-01). VKN was supported by a NIH Research Project
Grant on Breast Cancer Disparities (RO1-ES028802) and the CDC through the National
Institute for Occupational Safety and Health (NIOSH) Pilot Project Research Training
Program (T42-OH008455). KLF received support from The University of Michigan NIDA
Training Program in Neuroscience (T32-DA7281) and from the NIH Early Stage Train-
ing in the Neurosciences Training Grant (T32-NS076401). MO received support from
the Advanced Proteome Informatics of Cancer Training Grant (T32 CA140044). SNT
was supported by the Molecular Mechanisms in Microbial Pathogenesis training grant
(NIH T32 AI007528). ZL and BNW received support from the NIH Training Program in
Genomic Science (T32-HG000040-22).
Author Contributions
MD, KLS, ZL, and BNW wrote the initial draft of the manuscript. All authors contributed
to the curriculum and reviewed the manuscript.
Duda et al., (2021). Teaching Python for Data Science: Collaborative development of a modular & interactive curriculum. Journal of Open 7
Source Education, 4(46), 138. [Link]
Conflicts of Interest
None.
References
Becker, E. (2016). Responding to your Learners. In Data Carpentry. [Link]
assessment.
Benbow, R. J., & Vivyan, E. (2016). Gender and Belonging in Undergraduate Computer
Science: A Comparative Case Study of Student Experiences in Gateway Courses.
Bonham, K. S., & Stefan, M. I. (2017). Women are underrepresented in computa-
tional biology: An analysis of the scholarly literature in biology, computer science
and computational biology. PLOS Computational Biology, 13(10), e1005134. https:
//[Link]/10.1371/[Link].1005134
Fisher, D., & Frey, N. (2013). Better Learning Through Structured Teaching: A Frame-
work for the Gradual Release of Responsibility, 2nd Edition.
Girls Who Code HQ. (2021). Girls Who Code Project Gallery. [Link]
gallery.
Hannay, J. E., Dybå, T., Arisholm, E., & Sjøberg, D. I. K. (2009). The effectiveness
of pair programming: A meta-analysis. Information and Software Technology, 51(7),
1110–1122. [Link]
Harris, C. R., Millman, K. J., van der Walt, S. J., Gommers, R., Virtanen, P., Cournapeau,
D., Wieser, E., Taylor, J., Berg, S., Smith, N. J., Kern, R., Picus, M., Hoyer, S., van
Kerkwijk, M. H., Brett, M., Haldane, A., del Río, J. F., Wiebe, M., Peterson, P.,
… Oliphant, T. E. (2020). Array programming with NumPy. Nature, 585(7825),
357–362. [Link]
Hill, C., Corbett, C., & St. Rose, A. (2010). Why so few? Women in science, technology,
engineering, and mathematics. AAUW. ISBN: 978-1-879922-40-2
Hunter, J. D. (2007). Matplotlib: A 2D graphics environment. Computing in Science
Engineering, 9(3), 90–95. [Link]
Lapp, Z., Sovacool, K. L., Lesniak, N. A., King, D., Barnier, C., Flickinger, M., Krüger,
J., Armour, C. R., Lapp, M. M., Tallant, J., Diao, R., Oneka, M., Tomkovich, S.,
Anderson, J. M., Lucas, S. K., & Schloss, P. D. (2021). Developing and deploy-
ing an integrated workshop curriculum teaching computational skills for reproducible
research. bioRxiv. [Link]
National Center for Education Statistics. (2012). Digest of Education Statistics.
[Link] National Center for
Education Statistics.
Nederbragt, A., Harris, R. M., Hill, A. P., & Wilson, G. (2020). Ten quick tips for teaching
with participatory live coding. PLOS Computational Biology, 16(9), e1008090. https:
//[Link]/10.1371/[Link].1008090
PYPL PopularitY of Programming Language index. (n.d.). [Link]
Saujani, R. (2015). Girls Who Code: Annual Report 2015. [Link]
Stansell, A. (2019). Breaking Down the 50 Best Jobs in America for 2019 - Glassdoor. In
Glassdoor Economic Research. [Link]
Duda et al., (2021). Teaching Python for Data Science: Collaborative development of a modular & interactive curriculum. Journal of Open 8
Source Education, 4(46), 138. [Link]
Waskom, M. (2021). Seaborn: Statistical data visualization. JOSS, 6(60), 3021. https:
//[Link]/10.21105/joss.03021
Wilson, G. (2016). Software Carpentry: Lessons learned. F1000Res, 3, 62. [Link]
org/10.12688/f1000research.3-62.v2
Duda et al., (2021). Teaching Python for Data Science: Collaborative development of a modular & interactive curriculum. Journal of Open 9
Source Education, 4(46), 138. [Link]