Become an expert in R — Interactive courses, Cheat Sheets, certificates and more!
Get Started for Free

as.data.frame-methods

S3-type method for RasterArray and SpatialArray


Description

Convert RasterArray class objects to data.frames allowing View(), head() and tail() to work.

Usage

## S3 method for class 'RasterArray'
as.data.frame(x, row.names = NULL, optional = FALSE, ...)

## S3 method for class 'SpatialArray'
as.data.frame(x, row.names = NULL, optional = FALSE, ...)

Arguments

x

a RasterArray and SpatialArray class object.

row.names

Argument to define the rownames of the resulting data.frame.

optional

logical Flag to reset the rownames and colnaems attributes.

...

additional arguments passed to and from methods.

Details

Formal conversion method transforming the proxy object to a data.frame.

Value

A data.frame class object.

Examples

data(dems)
df <- as.data.frame(dems)

chronosphere

Earth System History Variables

v0.4.1
CC BY 4.0
Authors
Adam T. Kocsis, Nussaibah B. Raja
Initial release
2021-04-16

We don't support your browser anymore

Please choose more modern alternatives, such as Google Chrome or Mozilla Firefox.