Learn R Programming

prevR (version 3.1)

NA.outside.SpatialPolygons: Affect NA value to points located outside a polygon.

Description

This function forces points of an object of class SpatialPixelsDataFrame located outside the limits defined by an object of class SpatialPolygons to NA.

Usage

NA.outside.SpatialPolygons(sp.data, sp.poly)

Arguments

sp.data
object of class SpatialPixelsDataFrame.
sp.poly
object of class SpatialPolygons.

Value

  • Return sp.data modified.

See Also

point.in.SpatialPolygons.