Shiny for RStudio Exploring Web Mapping Technology With Isnardo Gandarilla & Ian Amitin
General Overview “RStudio is an integrated development environment (IDE) for R. It includes a console, syntax-highlighting editor that supports direct code execution, as well as tools for plotting, history, debugging and workspace management.” Basically, it’s a scripting program with its own programming language. A Shiny App delivers an R script to audience in a format that does not require the audience to know R. However, you definitely need to know how to write script in R to even begin to try to plot a map using Shiny.
General Overview To use Shiny, you need to how to build the app you have in mind using an R script. You also need some type of web server to service the app for display on the web.
Documentation Go to http://shiny.rstudio.com/tutorial/ for a 2.5 hour tutorial video on how to use Shiny in RStudio. You can skip to specific sections of the tutorial using the links provided on the page.
Documentation A map-specific tutorial is available at: http://shiny.rstudio.com/tutorial/lesson5/
Documentation To get started learning RStudio you can access the free Data Camp tutorial: https://www.datacamp.com/courses/free-introduction-to-r
Basic Functionality Table Data Manipulation: Joining Field Calculation Column Shape Manipulation Shapefiles Store Data in a .dbf Spatial Data Manipulation: Points Lines Polygons Rasters Special Custom Objects (e.g. datacubes, networks, etc) Works Cited: Jackson Voelkel
Advanced Functionality Plotting Vector Data Classification Custom Colors Raster Data Mathematical calculation (like Raster Calculator in ArcMap) Raster editing (clipping, mosaicking) Reclassification Works Cited: Jackson Voelkel
Shiny Functionality The Map Widget Allows you to create a map using the “Leaflet” package. Provides the following functionality: Map tiles (Basemaps) Markers / Circle Markers Polygons / Rectangles Lines Popups GeoJSON / TopoJSON Raster Images Color Legends Layer Groups and Layer Control
Programming Language You need to know R to use Shiny, as Shiny is just a package available in R. JavaScript would be helpful too.
Interactive Map Example Jackson Voelkel’s Interactive Map
Mash-Ups! Leaflet D3 Dygraphs Numerous HTML and CSS Themes.
Extras The ‘rgeos’ library in R is your friend! Learn R first. Are you ready for Shiny? … We were not!