Description Usage Arguments Details Author(s) References See Also Examples
downloadMODIS
downloads MODIS Vegetation Index data queried by
get_products.
1 | downloadMODIS(gSD_query, out_dir, use_aria = TRUE, do_par = TRUE, cores = NA)
|
gSD_query |
records data.frame. A valid query result returned by get_products. |
out_dir |
out_dir character. Full path to download output directory. |
use_aria |
optional logical. If True, aria2c is used for bulk downloading the selected images.
Requires valid aria2 installation. For help, see https://aria2.github.io/.
Default is |
do_par |
optional logical. Whether parallel download should be applied. This parameter is ignored
when |
cores |
optional integer. Number of cores used for parallel download. If |
Selected MODIS tiles are downloaded as .hdf archives from the Level-1 and Atmosphere Archive & Distribution System (LAADS) of NASA's Distributed Active Archive Center (DAAC) at the Goddard Space Flight Center in Greenbelt, Maryland (https://ladsweb.modaps.eosdis.nasa.gov/)
Sandro Groth
Jakob Schwalb-Willmann (2018). getSpatialData: Get different kinds of freely available spatial datasets. R package version 0.0.4. http://www.github.com/16eagle/getSpatialData/
prepMODIS get_products
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 | ## Import packages
## Not run:
library(getSpatialData)
library(sf)
## Set query parameters
aoi_data <- data("aoi_data")
set_aoi(aoi_data[[1]])
time_range <- c("2017-01-01", "2017-12-31")
## Login to USGS
loginUSGS("Username")
loginEarthData("Username")
## get available products
product_names <- get_products("MODIS")
product <- grep("MOD13Q1", product_names, value = T)
## Execute query
query <- getMODIS_records(time_range = time_range, name = product)
## Download all selected tiles
donwloadMODIS(query, "path/to/directory")
## End(Not run)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.