getCOLLECTION: Retrieve available version of MODIS product collections

Description Usage Arguments Value Author(s) See Also Examples

Description

This function will become internal. It will be used if no collection is spezified in the different functions i.e.: getHDF

Usage

1
getCOLLECTION(LocalArcPath,product,collection,newest=TRUE,forceCheck=FALSE)

Arguments

LocalArcPath

Character. Is needed because this funtion creates a hidden folder to store ftp directory inforamtion. If left empty standard path is used see ?getHDF

product

Character. MODIS grid product to check collections. For 'MODIS TERRA Vegetation Indices at 250 m ground resolution' use: MOD13Q1. For vegetation indices from TERRA and AQUA use MxD13Q1. See https://lpdaac.usgs.gov/lpdaac/products/modis_products_table for more Products.

collection

If provided the function only checks it the product exists TRUE or FALSE is the value it returns in this case.

newest

Logical. Default TRUE, return only the number of the newest collection.

forceCheck

Logical. Default FALSE, if TRUE the function connects to the FTP and gets the available collection. Since the collections doesn't change very frequently this check is rarely needed.

Value

A three digits integer converted to character, indicating the collection version(s). And a file in an hidden folder /MODIS_ARC/.auxiliaries/collections.txt as database for further calls. if collection is provided only a TRUE or FALSE is retuned!

Author(s)

Matteo Mattiuzzi

See Also

getPRODUCT

Examples

1
2
3
4
5
6
# update or get the existing collections for MOD11C3 and MYD11C3
getCOLLECTION(product="MxD11C3")
getCOLLECTION(product="MxD11C3",newest=FALSE)

getCOLLECTION(product="MxD11C3",collection=3)
getCOLLECTION(product="MxD11C3",collection=41)

getMODIS documentation built on May 2, 2019, 4:51 p.m.