
Interactively select aerial photos to download
select_photos.RdProvides a simple console-based interactive workflow to help users select
a subset of photos returned by find_photos(). The user chooses: a year,
a color type and the number of photos to keep
Arguments
- photos
An
sfobject ordata.frameproduced byfind_photos().- outdir
characterorNULL; Directory where photos will be saved. Defaults toNULL, in which case the package user overwrite directory (tools::R_user_dir()) is used.
Value
Invisibly returns a subset of photos corresponding to the user
selection. Returns NULL invisibly if the user quits.
Details
This function does not download files. It only returns the selected
rows (typically to be passed to get_photos()).
Internal color codes are mapped as follows:
"P"->"PHOTO"(panchromatic / black & white)"C"->"RGB"(color)"IR"`` ->"IRC"` (infrared)"IRC"`` ->"IRC"` (infrared color)
Examples
if (FALSE) { # \dontrun{
x <- sf::read_sf("my_area.gpkg")
photos <- find_photos(x)
sel <- select_photos(photos)
# Then download:
get_photos(sel$url, outdir = tempdir(), mode = "raw")
} # }