Following the Github link will show the code that I used to run the program as well as instructions to get it running.
This app visualizes ridership throughout the entire CTA "El" Station. Front and center are a bar chart indicating the ridership at each station for a given date as well as a map with markers that indicate the ridership based on opacity and marker size.
The viewer can opt to choose a date to see the ridership for that specific date, and choose two dates to see the change in ridership between the two dates.
A particular stop can be highlighted by selecting from a list of them or tapping on a marker. At first, bar charts showing the ridership for each year from 2001 to 2021, ridership per month for a given year, ridership per day for a given year, and ridership per weekday for a given year.
When selecting a particular stop, a year slider can be used to change the visualizations for the stop. By default, each visualization is a bar chart but can be changed to a table.
Data files that could not fit on github:
https://data.cityofchicago.org/Transportation/CTA-System-Information-List-of-L-Stops/8pix-ypme
Choose the export option and download it as a TSV for Excel.
https://data.cityofchicago.org/Transportation/CTA-Ridership-L-Station-Entries-Daily-Totals/5neh-572f
Choose the export option and download it as a TSV for Excel.
In order to get the code that is found at the discord link, be sure to install R and RStudio
Navigate to this link and choose the version that corresponds to your version of MacOS. (version 4.1.3)
Navigate to this link to download R for Windows. (version 4.1.3)
Download RStudio (desktop version, the free one)
Follow the github link, click the Code button, and select the download ZIP option.
Open up RStudio and create an RProject. You may choose any directory you would like in your file system.
TMove the downloaded unzipped files as well as the data files listed at the top into the directory.
Once in RStudio, you may need to install some packages.
Click the Packages tab and choose the Install option.
Install the following packages if they are not listed in the System Library:
ggplot2
scales
lubridate
dplyr
shiny
leaflet
stringr
forcats
DT
Assure that all of the numbered TSV files are in the directory. Then, run the p2script.R file.
This is the menu to manipulate the display.
You may decide how the top bar chart can be displayed.
It can be displayed as a bar chart or table.
You may also sort it by ABC order or ascending order.
You may also choose how many dates you would like to see.
One date: Shows the ridership data on a specific date.
Two dates: Shows the change in ridership between two dates.
You may also choose a stop to view
Choose whether to see some stop data
This list contains every stop in alphabetical order
Change the visualization of the individual stop data if you would like
Change the year.
This will update each newly-rendered bar charts or tables.
Select a date
Change the month
Change the year
Visualization with stop data shown with one date in the center.
Visualization with stop date shown with two dates to show the difference in the center.
Visualization with stop date shown as tables (ascending order)