gt_writeRaster: Write geotrellis raster to file

Description Usage Arguments Value Examples

View source: R/gt_writeRaster.R

Description

Save a gt_RasterLayer object to disk in a GeoTIFF format.

Usage

1
gt_writeRaster(x, path, overwrite = FALSE)

Arguments

x

gt_RasterLayer object.

path

character file path.

overwrite

character if the file path specifed in path already exists should it be overwritten? Defaults to FALSE.

Value

invisible(). This function is used for its side-effect of producing files on disk.

Examples

1
2
3
4
5
6
7
## Not run: 
g <- gt_raster(raster::raster(matrix(runif(9), ncol=3),
                              crs=sp::CRS('+init=epsg:4326'),
                              xmn=0, xmx=3, ymn=2, ymx=10))
gt_writeRaster(g, tempfile(fileext='.tif'))

## End(Not run)

jeffreyhanson/geotrellis documentation built on May 19, 2019, 4 a.m.