convertGrid: Convert EASE-grid netCDF to 'raster' object

Description Usage Arguments Value Examples

View source: R/convertGrid.R

Description

Converts an EASE-grid format netCDF file to raster object through the raster package.

Usage

1
2
convertGrid(nc_path = NULL, name = NULL, lon = NULL, lat = NULL,
  vals = NULL, inCRS = "+init=epsg:4053")

Arguments

nc_path

Path to netCDF file. Defaults to NULL. Required if lon, lat, and vals arguments are not supplied.

name

Name of variable to extract. Defaults to NULL Required if lon, lat, and vals arguments are not supplied.

lon

Optional vector of longitudinal coordinates. Defaults to NULL. Required if nc_path and name arguments are not supplied.

lat

Optional vector of latitudinal coordinates. Defaults to NULL. Required if nc_path and name arguments are not supplied.

vals

Optional matrix of measured values. Defaults to NULL. Required if nc_path and name arguments are not supplied.

inCRS

CRS object of dataset projection system. Defaults to '+init=epsg:4053'.

Value

raster object

Examples

1
2
convertGrid(nc_path = '.../smos.nc', name = 'Soil_Moisture')
convertGrid(lon = lon_vector, lat = lat_vector, vals = vals_matrix)

ssaxe-usgs/EASEgridR documentation built on May 27, 2019, 3:32 p.m.