as.data.grid: data.grid-class methods

View source: R/data.grid.R

as.data.gridR Documentation

data.grid-class methods

Description

S3 class data.grid methods.

Usage

as.data.grid(object, ...)

## S3 method for class 'SpatialGridDataFrame'
as.data.grid(object, data.ind = NULL, ...)

## S3 method for class 'data.grid'
as.data.frame(
  x,
  row.names = NULL,
  optional = FALSE,
  data.ind = NULL,
  coords = FALSE,
  sp = FALSE,
  check.names = coords,
  ...
)

Arguments

object

(gridded data) used to select a method.

...

further arguments passed to data.grid.

data.ind

integer or character vector with the indexes or names of the components.

x

a data.grid object.

row.names

NULL, column to be used as row names, or vector giving the row names for the data frame.

optional

logical; Not currently used (see as.data.frame).

coords

logical; if TRUE, the (spatial) coordinates of the object are added.

sp

logical; if TRUE, the second dimension of the data is reversed (as it is stored in sp package).

check.names

logical; if TRUE, the names of the variables in the data frame are checked and adjusted if necessary.

Value

as.data.grid returns a data.grid object.

as.data.frame returns a data frame.

See Also

data.grid.


npsp documentation built on May 29, 2024, 5:31 a.m.