Skip to content

Commit

Permalink
describe SpatVector polygon inputs in adjacent.Rd
Browse files Browse the repository at this point in the history
  • Loading branch information
AMBarbosa authored Jan 17, 2025
1 parent 2a3aa0b commit 75c02a7
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions man/adjacent.Rd
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
\alias{adjacent,SpatRaster-method}
\alias{adjacent,SpatVector-method}

\title{Adjacent cells}
\title{Adjacent cells or polygons}

\description{
Identify cells that are adjacent to a set of raster cells. Or identify adjacent polygons
Expand All @@ -19,7 +19,7 @@ Identify cells that are adjacent to a set of raster cells. Or identify adjacent
}

\arguments{
\item{x}{SpatRaster}
\item{x}{SpatRaster, or SpatVector of polygons}
\item{cells}{vector of cell numbers for which adjacent cells should be found. Cell numbers start with 1 in the upper-left corner and increase from left to right and from top to bottom}
\item{directions}{character or matrix to indicated the directions in which cells are considered connected. The following character values are allowed: "rook" or "4" for the horizontal and vertical neighbors; "bishop" to get the diagonal neighbors; "queen" or "8" to get the vertical, horizontal and diagonal neighbors; or "16" for knight and one-cell queen move neighbors. If \code{directions} is a matrix it should have odd dimensions and have logical (or 0, 1) values}
\item{pairs}{logical. If \code{TRUE}, a two-column matrix of pairs of adjacent cells is returned. If \code{x} is a \code{SpatRaster} and \code{pairs} is \code{FALSE}, an \code{n*m} matrix is returned where the number of rows \code{n} is \code{length(cells)} and the number of columns \code{m} is the number of neighbors requested with \code{directions}}
Expand All @@ -33,7 +33,7 @@ When using global lon/lat rasters, adjacent cells at the other side of the date-
}


\seealso{\code{\link{relate}}, \code{\link{nearby}}}
\seealso{\code{\link{relate}}, \code{\link{nearby}}}, \code{\link{nearest}}}

\value{
matrix
Expand Down

0 comments on commit 75c02a7

Please sign in to comment.