When most folks think about archaeology, there is a tendency to think about an extinct human past. For example, viewing the artifacts of the archaeological world in museums often sanitizes them as being stuck in a static past and of no consequence to the human present. In an effort to breathe life into our shared human heritage, I’ve endeavored to provide an interactive dashboard to my archaeological colleagues and the public alike. This post details the technical aspects of creating such an interactive experience using Flexdashboard and Shiny in the R statistical language. The dashboard highlights a number of my personal interests in programming, including the creation of interactive social network models, interactive exploratory data analysis, and bringing statistical reports to an online format. By the end of this tutorial, you should have a solid foundation on how to build an interactive document using Shiny and Flexdashboard in R!

Building a Dashboard with Flexdashboard

If you’re more interested in statistical analysis than website design, flexdashboards are a great way to gain entry into the online publishing world without much investment in learning a bunch of new code or having to deal with hosting issues (you can host your flexdashboard on ShinyApps.io at a free pricing tier).

A good dashboard starts out with a good idea about presenting data, an analysis, or both. Maybe you want to allow a user to explore home prices in their area, look at sales data at different time scales, check the tide level, or (like the dashboard presented here) turn a static powerpoint presentation into an interactive online resource.

The first step in RStudio is to create a fresh R Markdown document