SDF2simulations: Turn a SpatialDataFrame into Simulations.

Description Usage Arguments Details Value Author(s) Examples

View source: R/SDF2simulations.R

Description

Turn a SpatialDataFrame into Simulations: turn some of the data into the values, keep the others as the data of the locations.

Usage

1
SDF2simulations(x, indices = matrix(1:ncol(x@data), nrow = 1))

Arguments

x

SpatialDataFrame

indices

matrix of integers indicating the columns of the data to be transformed to values; each row stands for a kind of values

Details

This function can be used to extract the maps in Simulations objects: the values are assigned to the spatial properties, for plotting, combining it with other spatial data etc. As the size of all values may exceed the memory, it may extract only the first of the kinds and plumes.

Value

A SpatialDataFrame with the same spatial reference as the locations of the obj with the values of the chosen plume and layer as attribute.

Author(s)

Kristina B. Helle, kristina.helle@uni-muenster.de

Examples

1
2
3
4
data(SimulationsSmall)
SimulationsSmall_134_21 = extractSpatialDataFrame(
  SimulationsSmall,
  plumes = c(1,3,4), kinds = c(2,1))

KristinaHelle/sensors4plumes documentation built on May 7, 2019, 12:31 p.m.