tiles_functions: Tiles functions

Description Usage Arguments Details Value Functions See Also Examples

Description

These functions provide operations to work with tiles registered in cubes.

Usage

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11

Arguments

which

A logical or integer vector indicating which tile to be fetched. If NULL (default) all tiles are fetched.

cube

A EOCubes_cube object.

prefix

A character vector containing tile's name prefixes to be filtered.

geom

A sfc, a sf object, or a character path to a shapefile to filter intersecting tiles.

cache

A logical or NULL to enable (TRUE), disable (FALSE), or proceed the default behavior of (NULL) the cache system.

progress_bar

A logical value indicating to show or not a progress bar while fetching tiles.

Details

The function .verify_which is a internal function used to verify the consistency of which parameter of some tiles functions.

The function tiles_which requires sf package to compute intersection. It can be used in which parameter of functions cube_filter, stacks, tiles_which

Fetching tiles can be an expensive task. You can filter tiles that intersects your area of interest by providing which parameter.

The function cubes_sfc requires sf package.

The function tiles_to_sfc requires sf package.

Value

Either a logical or integer vector.

A logical vector.

An EOCubes_tilelist object that lists all tiles from a cube.

An EOCubes_tiles object.

A sfc object from sf package.

A sfc object from sf package.

Functions

See Also

remote, cube, cube_filter

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
x <- remote("localhost")
cub1 <- cube("MOD13Q1/006", x)
tiles_index <- tiles_which(cub1, "h13v10")   # select 'h13v10' tile

# required by sf package
if (require("tibble") && require("sf")) {

   tiles_sfc(cub1, which = tiles_index)
   file <- system.file("shape/example.shp", package = "EOCubes")
   tiles_index <- tiles_which(cub1, geom = file)   # select all tiles that intersect shapefile
   tiles_sfc(cub1, which = tiles_index)
}

e-sensing/EOCubes documentation built on Oct. 21, 2019, 2:30 a.m.