Learn R Programming

shinyscholar (version 0.2.5)

select_user: Load a raster image

Description

Called by the select_user module in the example app and loads a .tif file as a SpatRaster

Usage

select_user(raster_path, logger = NULL)

Value

a SpatRaster object

Arguments

raster_path

character. Path to file to be loaded

logger

Stores all notification messages to be displayed in the Log Window. Insert the logger reactive list here for running in shiny, otherwise leave the default NULL

Author

Simon Smart simon.smart@cantab.net

Examples

Run this code
if (check_suggests(example = TRUE)) {
  raster_path <- list.files(system.file("extdata", "wc", package = "shinyscholar"),
  full.names = TRUE)
  raster <- select_user(raster_path)
} else {
  message('reinstall with install.packages("shinyscholar", dependencies = TRUE)
  to run this example')
}

Run the code above in your browser using DataLab