View source: R/satfile_funcs.R
download_oc | R Documentation |
Download file lists from functions get_imglist_multi() and get_imglist_l1()
download_oc(filenames, urls)
filenames |
Filename to download |
urls |
URLs of files corresponding to filenames |
Uses wget (works on Mac, Linux, or Cygwin from Windows), and you need to have the OBPG .netrc credentials, i.e. you need to create an Earthdata account, and then type the following on the command line, replacing USERNAME and PASSWD with your own username and password:
echo "machine urs.earthdata.nasa.gov login USERNAME password PASSWD" > ~/.netrc ; > ~/.urs_cookies
chmod 0600 ~/.netrc
See "Download Methods" here for more details: https://oceancolor.gsfc.nasa.gov/data/download_methods/
Data.frame with metadata and URLs of files to download.
filename = "A2003001162000.L2_LAC_OC.nc"
url = "https://oceandata.sci.gsfc.nasa.gov/cmr/getfile/A2003001162000.L2_LAC_OC.nc"
download_oc(filename, url)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.