GSS Explorer
  • Explorer
  • About

About

About This Demo

This dashboard explores data from the General Social Survey (GSS), one of the longest-running surveys in the United States.

Use the sidebar filters on the Explorer page to slice the data by time period and demographic breakdowns. The dashboard automatically updates charts based on your filter selections.

Features Demonstrated

  • Sidebar layout with radio button filters
  • Stacked bar charts with percentage and count modes
  • Timeline charts for tracking trends over time
  • Conditional visibility (show_when) to display different chart types based on filter state
  • Dynamic titles that update based on selected filters

Usage

create_page("Explorer", layout = "sidebar") %>%
  begin_sidebar() %>%
    add_input(type = "radio", filter_var = "time_period", ...) %>%
    add_input(type = "radio", filter_var = "breakdown_type", ...) %>%
  end_sidebar() %>%
  add_viz(type = "stackedbar", show_when = ~ time_period != "Over Time") %>%
  add_viz(type = "timeline", show_when = ~ time_period == "Over Time")

Source Code

The full R code that generates this dashboard is available on GitHub:

  • View Source Code

Learn More

  • dashboardr Documentation
  • Community Gallery
 
 

Built with dashboardr