Learn R Programming

satellite (version 1.0.5)

satellite: Create a Satellite object

Description

Method to create a Satellite object.

Usage

# S4 method for character
satellite(x, meta, log)

# S4 method for Raster satellite(x, meta, log)

# S4 method for list satellite(x, meta, log)

Value

A Satellite object.

Arguments

x

A vector of filenames, a (multi-layered) Raster* object or a list of single RasterLayer objects (see raster). In the latter case, be aware that bands must be arranged in ascending order (eg using sortFilesLandsat).

meta

Optional metadata object (e.g. returned from compMetaLandsat). If 'x' is a satellite dataset and recognised as "Landsat", then the metadata is automatically extracted from the respective meta information file if both the satellite data and the metadata file follow the USGS Earth Explorer's naming convention.

log

Optionally supply a log entry.

Details

A Satellite object consists of three data sections: (i) a raster data section which holds the actual data values of the respective sensor bands, (ii) a metadata grid which holds meta information for each sensor band (e.g. calibration coefficients, type of sensor band etc.) and (iii) a list of log information which records the processing history of the entire dataset.

See Also

(i) compMetaLandsat to get more information about the structure of the metadata component; (ii) https://www.usgs.gov/faqs/what-naming-convention-landsat-collections-level-1-scenes?qt-news_science_products=0#qt-news_science_products for detailed information about the naming conventions for Landsat scene identifiers; and (iii) sortFilesLandsat for automated rearrangement of Landsat band files.

Examples

Run this code
## 'character' input (i.e. filenames)
path <- system.file("extdata", package = "satellite")
files <- list.files(path, pattern = glob2rx("LC08*.TIF"), full.names = TRUE)

satellite(files)

## raster::RasterStack input
satellite(l8)

Run the code above in your browser using DataLab