Portfolio Project 1
Posing and answering research questions
Overview
In your first portfolio project, you’ll explore a dataset and pose your own research questions. You’ll then apply what you’ve learned about ggplot2 and design principles to answer the questions.
Your final report should include
- A paragraph introduction to your data
- A section for Research Question 1 that includes:
- Your question
- Why that question is interesting/important
- A graph that answers the question
- A written answer to the question based on the graph
- A section for Research Question 2 that includes:
- Your question. This should focus on a variable that was not included in Research Question 1.
- Why that question is interesting/important
- A graph that answers the question
- A written answer to the question based on the graph
- A section describing your design choices
- This should be about a paragraph telling me why you chose the geometries, aesthetics, scales, themes, etc. that you did
Each of the two questions you come up with should involve more than two variables to answer. You should phrase them in a way that the is within the scope of inference of your data. For example, if you have an observational dataset, you shouldn’t phrase your question in a causal way. Your questions shouldn’t be identical to the example questions in the TidyTuesday repo pages.
Your rendered file should not echo the code used to create the graphs, but the code in your .qmd should be clean and readable. Your report should not be long! If rendering to a PDF, I expect the entire report to be about 3 pages.
Options
Choosing a dataset is something you should do carefully but also relatively quickly. The dataset you choose should allow for two distinct questions to be asked and answered using a not-completely-overlapping set of variables, i.e., Question 1 requires the use of variables x, y, and z and Question 2 requires the use of variables a, b, c, and d or x, a, and b. Some shared variables are ok, but the set of variables should not be completely overlapping, i.e., Question 2 can’t also require the use of variables x, y, and z.
1. Income Inequality before and after taxes
# A tibble: 15,710 × 7
Entity Code Year gini_disposable__age_total gini_market__age_total
<chr> <chr> <dbl> <dbl> <dbl>
1 Afghanistan AFG 1964 NA NA
2 Afghanistan AFG 1965 NA NA
3 Afghanistan AFG 1966 NA NA
4 Afghanistan AFG 1967 NA NA
5 Afghanistan AFG 1968 NA NA
6 Afghanistan AFG 1969 NA NA
7 Afghanistan AFG 1970 NA NA
8 Afghanistan AFG 1971 NA NA
9 Afghanistan AFG 1972 NA NA
10 Afghanistan AFG 1973 NA NA
# ℹ 15,700 more rows
# ℹ 2 more variables: population_historical <dbl>, owid_region <chr>
For more information about the variables in the dataset, see the TidyTuesday repo page. For more information about the data itself, read the original Our World In Data article.
2. Billboard Hot100 Number Ones
billboard <- readr::read_csv('https://raw.githubusercontent.com/rfordatascience/tidytuesday/main/data/2025/2025-08-26/billboard.csv')
billboard# A tibble: 1,177 × 105
song artist date weeks_at_number_one non_consecutive rating_1
<chr> <chr> <dttm> <dbl> <dbl> <dbl>
1 Poor… Ricky… 1958-08-04 00:00:00 2 0 4
2 Nel … Domen… 1958-08-18 00:00:00 5 1 7
3 Litt… The E… 1958-08-25 00:00:00 1 0 5
4 It's… Tommy… 1958-09-29 00:00:00 6 0 3
5 It's… Conwa… 1958-11-10 00:00:00 2 1 7
6 Tom … The K… 1958-11-17 00:00:00 1 0 5
7 To K… The T… 1958-12-01 00:00:00 3 0 8
8 The … The C… 1958-12-22 00:00:00 4 0 1
9 Smok… The P… 1959-01-19 00:00:00 3 0 9
10 Stag… Lloyd… 1959-02-02 00:00:00 4 0 6
# ℹ 1,167 more rows
# ℹ 99 more variables: rating_2 <dbl>, rating_3 <dbl>, overall_rating <dbl>,
# divisiveness <dbl>, label <chr>, parent_label <chr>, cdr_genre <chr>,
# cdr_style <chr>, discogs_genre <chr>, discogs_style <chr>,
# artist_structure <dbl>, featured_artists <chr>,
# multiple_lead_vocalists <dbl>, group_named_after_non_lead_singer <dbl>,
# talent_contestant <chr>, posthumous <dbl>, artist_place_of_origin <chr>, …
For more information about the variables in the dataset, see the TidyTuesday repo page. For more information about the data itself and an example analysis, see the *Can’t get much higher newsletter.
3. NSF grant terminations
nsf_terminations <- readr::read_csv('https://raw.githubusercontent.com/rfordatascience/tidytuesday/main/data/2025/2025-05-06/nsf_terminations.csv')
nsf_terminations# A tibble: 1,041 × 21
grant_number project_title termination_letter_d…¹ org_name org_city org_state
<dbl> <chr> <date> <chr> <chr> <chr>
1 2135329 Collaborativ… 2025-04-25 Univers… ALBUQUE… NM
2 2342099 MyTurn: An A… 2025-04-25 Univers… CHICAGO IL
3 2201103 Collaborativ… 2025-04-25 America… WASHING… DC
4 2215382 Engaging Rur… 2025-04-25 TERC Inc CAMBRID… MA
5 2405633 Design Effec… 2025-04-25 San Fra… SAN FRA… CA
6 2317714 Collaborativ… 2025-04-25 Occiden… LOS ANG… CA
7 2046081 CAREER: SBP:… 2025-04-25 Univers… SANTA B… CA
8 2348705 Rural Commun… 2025-04-25 Hamilto… CLINTON NY
9 2404708 Postdoctoral… 2025-04-25 New Yor… New York CA
10 2215138 BRITE Girls … 2025-04-25 Florida… TALLAHA… FL
# ℹ 1,031 more rows
# ℹ abbreviated name: ¹termination_letter_date
# ℹ 15 more variables: org_district <chr>, usaspending_obligated <dbl>,
# award_type <chr>, directorate_abbrev <chr>, directorate <chr>,
# division <chr>, nsf_program_name <chr>, nsf_url <chr>,
# usaspending_url <chr>, nsf_startdate <date>, nsf_expected_end_date <date>,
# org_zip <chr>, org_uei <chr>, abstract <chr>, in_cruz_list <lgl>
For more information about the variables in the dataset, see the TidyTuesday repo page. For more information about the data itself, see Grant Watch.
4. Water Quality at Sydney Beaches
water_quality <- readr::read_csv('https://raw.githubusercontent.com/rfordatascience/tidytuesday/main/data/2025/2025-05-20/water_quality.csv')
water_quality# A tibble: 123,530 × 10
region council swim_site date time enterococci_cfu_100ml
<chr> <chr> <chr> <date> <tim> <dbl>
1 Western Sydney Hawkesbury C… Windsor … 2025-04-28 11:00 620
2 Sydney Harbour North Sydney… Hayes St… 2025-04-28 11:40 64
3 Sydney Harbour Willoughby C… Northbri… 2025-04-28 10:54 160
4 Sydney Harbour Northern Bea… Fairligh… 2025-04-28 09:28 54
5 Western Sydney Hawkesbury C… Yarramun… 2025-04-28 10:35 720
6 Sydney Harbour Northern Bea… Little M… 2025-04-28 09:19 230
7 Sydney Harbour City of Cana… Chiswick… 2025-04-28 13:06 120
8 Sydney Harbour Inner West C… Dawn Fra… 2025-04-28 08:04 280
9 Sydney Harbour Woollahra Mu… Rose Bay… 2025-04-28 08:50 60
10 Sydney Harbour Woollahra Mu… Camp Cove 2025-04-28 09:09 100
# ℹ 123,520 more rows
# ℹ 4 more variables: water_temperature_c <dbl>, conductivity_ms_cm <dbl>,
# latitude <dbl>, longitude <dbl>
For more information about the variables in the dataset, see the TidyTuesday repo page. For more information about the data itself, see BeachWatch.
5. Pokemon
pokemon_df <- readr::read_csv('https://raw.githubusercontent.com/rfordatascience/tidytuesday/main/data/2025/2025-04-01/pokemon_df.csv')
pokemon_df# A tibble: 949 × 22
id pokemon species_id height weight base_experience type_1 type_2 hp
<dbl> <chr> <dbl> <dbl> <dbl> <dbl> <chr> <chr> <dbl>
1 1 bulbasaur 1 0.7 6.9 64 grass poison 45
2 2 ivysaur 2 1 13 142 grass poison 60
3 3 venusaur 3 2 100 236 grass poison 80
4 4 charmander 4 0.6 8.5 62 fire <NA> 39
5 5 charmeleon 5 1.1 19 142 fire <NA> 58
6 6 charizard 6 1.7 90.5 240 fire flying 78
7 7 squirtle 7 0.5 9 63 water <NA> 44
8 8 wartortle 8 1 22.5 142 water <NA> 59
9 9 blastoise 9 1.6 85.5 239 water <NA> 79
10 10 caterpie 10 0.3 2.9 39 bug <NA> 45
# ℹ 939 more rows
# ℹ 13 more variables: attack <dbl>, defense <dbl>, special_attack <dbl>,
# special_defense <dbl>, speed <dbl>, color_1 <chr>, color_2 <chr>,
# color_f <chr>, egg_group_1 <chr>, egg_group_2 <chr>, url_icon <chr>,
# generation_id <dbl>, url_image <chr>
For more information about the variables in the dataset, see the TidyTuesday repo page. For more information about the data itself, see PokeAPI.
6. BYO
If none of the options listed here speak to you, you can also choose your own dataset. The data should have at least two quantitative and two categorical variables, at least eight variables total, and be “complicated” enough to demonstrate an advanced understanding of ggplot and design principles from class. I’d encourage you to run your idea by me before diving too deep!
Submission
Your submission should include two visualizations (replication and improvement), a written overview of your work, and all associated code. You should work in a quarto file. Your rendered file can be either pdf or html. I will distribute GitHub skeleton repos that you should fill in as you work. You should commit your final code and output file to your repo and link your repo to gradescope to submit.
Rubric
A successful project will:
-
- There should be at least two commits with substantial changes between the two
-
- Very few grammatical mistakes, spelling mistakes, or typos
- Appropriate labels and font sizes
- A readable theme
- The rendered document does not contain any unnecessary content (package loading messages, warnings, etc.)
An excellent project will meet all of the requirements for a successful project, plus
This is an individual portfolio project.
FAQ
If you have any questions, please post them to Ed with the “portfolio projects” tag
