Skip to contents

Accessory function to get the full list of directories on the lpdaac http site containing data included in the time range selected for processing (modified after Barry Rowlingson function):

Usage

get_mod_dirs(
  http,
  download_server,
  user,
  password,
  yy,
  n_retries,
  gui,
  out_folder_mod
)

Arguments

http

character http site on lpdaac corresponding to the selected MODIS product

download_server

character ["http" | "offline"] download service to be used; if NA, the script tries to download with http.

user

character username for earthdata http server

password

character password for earthdata http server

yy

character Year for which the folder containing HDF images are to be identified

n_retries

numeric number of times the access to the http server should be retried in case of error before quitting, Default: 20

gui

`logical`` indicates if processing was called from the GUI environment or not. If not, processing messages are sent to a log file instead than to the console/GTK progress windows.

out_folder_mod

character output folder for MODIS HDF storage

Value

character array listing all available folders (a.k.a. dates) for the requested MODIS product on lpdaac http archive, for the years included in the time range selected for processing.

Note

License: GPL 3.0

Author

Original code by Babak Naimi (.getModisList, in ModisDownload.R) modified to adapt it to MODIStsp scheme and to http archive (instead than old FTP) by:

Lorenzo Busetto, phD (2014-2017)

Luigi Ranghetti, phD (2016-2017)