Launches an interactive Shiny application for exploring Focus–Glue–Context (FGC) fisheye lens transformations on geographic data. The app provides real-time lens positioning, adjustable distortion parameters, and side-by-side comparison of transformed and original views.
The application demonstrates fisheye effects on Victoria, Australia Local Government Areas (LGAs) with a network of healthcare facilities and aged care connections. Users can drag the lens to any position and adjust parameters without server-side re-rendering for smooth, responsive interaction.
Arguments
- ...
Additional arguments passed to
shiny::runApp(). Common options include:launch.browser: Logical or function to handle app launch (default =TRUE)port: Integer port number (default = random available port)host: Character host IP address (default ="127.0.0.1")display.mode: Character display mode,"auto","normal", or"showcase"
Value
Invisible NULL. The function is called for its side effect
of launching the Shiny application. The R session will be blocked
until the app is stopped (press Escape or close the browser window).
Details
Features
Interactive lens dragging: Click and drag anywhere on the map to reposition the fisheye lens in real-time
Parameter controls: Adjust inner radius (focus), outer radius (glue), zoom factor, and squeeze factor
Facility sampling: Randomly sample healthcare facilities and residential aged care facilities (RACFs) with adjustable sample size
Transfer visualization: Toggle display of patient transfer connections between facilities
Side-by-side comparison: Compare fisheye-transformed and original static views
Requirements
The Shiny app requires the following suggested packages:
shinytidyrdplyrpurrrggthemes
If any are missing, install with:
install.packages(c("shiny", "tidyr", "dplyr", "purrr", "ggthemes"))Implementation Notes
The app uses client-side JavaScript for smooth lens dragging without
server round-trips. Fisheye transformations match the mathematical
implementation in fisheye_fgc() and sf_fisheye(), applied to
polygons, lines, and points in real-time using SVG rendering.
See also
fisheye_fgc()for the core transformation functionsf_fisheye()for transforming spatial geometriesplot_fisheye_fgc()for static visualizationsshiny::runApp()for additional launch options
