Counts the number of neighbors a given cell has within a specified radius, useful for assessing habitat connectivity.
countNeighborsOLD(cell, cells, radius)
The cell for which to count neighbors.
The matrix of cells to check against.
The radius within which to count neighbors.
The count of neighbors within the specified radius.