Learn R Programming

dispeRse (version 1.1)

.to_grid: Convert from geographic coordinates in a given projection system to the relative position in rows and columns of a grid.

Description

Convert from geographic coordinates in a given projection system to the relative position in rows and columns of a grid.

Usage

.to_grid(coords, grid)

Value

A DataFrame with the converted coordinates.

Arguments

coords

A SpatialPointsDataFrame. Must contain a column dates with the start date of the dispersal from each point.

grid

A Raster*. The coordinates will be converted to this grid.