My First Shiny App

Tulio Criscuolo
June 19th, 2015

App description

  • The data set used in this app is the daily Ozone data from EPA air data for the year of 2013.

  • The raw data has 390491 rows and 28 columns, which has daily measure of the Ozone and Air quality index for stations across the United State.

  • The app displays, a map showing station locations and a table containing each station mean value of for Ozone and Airquality measuared in the year of 2013.

Data processing

  • Before the data is used in the app, the raw data is processed to computed the mean of the Ozone and Airquality measured by each station.
unzip("data/daily_44201_2013.csv.zip", exdir = "data/")
data <- read.csv("data/daily_44201_2013.csv", header = TRUE, sep = ",")
data <- (data[ , list(OZONE = round(mean(Arithmetic.Mean, na.rm = T), 2), 
                                 AQI = round(mean(AQI, na.rm = T), 0)),
                         by =  list(State.Code, County.Code, Site.Num, Longitude, Latitude, Address)]);
stateList <- unique(data$State.Code)
save(data, file = "data/data.Rda")
save(stateList, file = "data/stateList.Rda")

App interface

  • With the processed data, the app will render the result on table, this table contains all station.
  • When all stations are select it will not display them on the map bacause it takes to long to plot them.
  • There are five buttons to chance the result displayed.
  • Some buttons such as County, will only be unclocked after selecting a State.

Thank you

Useful links:

App github

EPA Air data