Data Visualizations
Tools: Shiny, R, GitHub
The project is hosted on shinyapps.io and includes three interactive charts exploring Washington report card enrollment trends using a multi-page layout. I created the bar chart looking at Gender X students by county (second tab).
Summary:
This project explores data on enrollments in K-12 education throughout Washington schools. I analyzed trends that can be used to create changes to the education system based on race, familial background, and gender within the 2019-2020 school year.
My group looked at how race impacts enrollment numbers throughout WA counties. Questions we asked throughout include:
How does the number of Gender X students change throughout grade levels?
How does family background affect student enrollment numbers?
How does race impact enrollment numbers throughout counties?
Visualization
The bar chart looks at the number of Gender X students in each grade level based on the Washington county input by the user.
The dataset focuses on the school year from 2019 to 2020. Gender X refers to students who don't identify as male or female, but rather fit outside this gender binary.
By choosing a county, the user can see how many students belong to this category amongst all the schools in that county. Hovering over a bar shows the Grade Level and number of Gender X students.
Problems
One of the main problems I had was figuring out how to change the color of each of the bar charts. Originally, I left the bars the default color of gray (since no legend is needed to explain the data). However, after checking with a TA, it was recommended to make each grade level a different color.
Making this change caused some issues with the hover created with Shiny, so I had to convert my chart from ggplot to plotly.
Another problem our group faced was working collaboratively with GitHub. Sometimes I had to completely delete my local repository and clone the project because of issues, but through good teamwork, we were able to share our separate work.
Visualizations take a few seconds to load
I explored trends in CO2 emissions using data compiled by Our World In Data.
The dataset examines CO2 and greenhouse gas emissions across various different countries around the world. The variables I examined include:
'year' - year each annual emission is from
‘country' - which region the data occurred in
'co2' - annual production-based emissions of carbon dioxide in million tonnes
I filtered to the top ten regions with the highest annual emissions of carbon dioxide.
Visualization and Design Reasoning
I was tasked to create an interactive visualization exploring trends from the dataset. I decided the make a line plot showing CO2 emission rates over time. I used ggplot2 to create the chart and plotly for the ability to hover over points.
I used 3 files, ui.R, server.R, and app.R, to clean up my work.
Within the UI, I connected output placeholders to my chart and defined what I wanted each widget to do; for example, I defined the choices for the themes users can pick.
For aesthetic purposes, I downloaded the shinythemes package to change the layout of the website. I hosted the website through Shiny for better accessibility.
Problems
I ran into many problems creating this visualization. For one, I had to figure out the best trends to analyze and how. I didn’t want the user to have an overwhelming number of choices, so I had to decide how I wanted to filter to a smaller amount of countries. I ended up filtering by the countries with the highest CO2 emissions during the latest year.
To achieve this, I played around with DPLYR to choose ten countries.