dist2nf: Distance to Natural forests

View source: R/dist2nf.R

dist2nfR Documentation

Distance to Natural forests

Description

dist2nf computes the distance between the target pine plantation and all surroundings natural forests patches.

Usage

dist2nf(x, nf_value)

Arguments

x

A raster object

nf_value

The value of "Natural Forests" landscape class within the raster (default value = 2).

Details

This auxiliary function calculates the distance for each pixel of the target pine plantation to the edges of all surrounding natural forest patches. For each pixel, the final value considered is the minimum of all distances from that pixel to the edges of natural forests.

Value

A raster object with the minimum distance for each raster pixel

Author(s)

Antonio J Pérez-Luque (ajpelu@gmail.com)


ajpelu/diverpine documentation built on Feb. 3, 2023, 8:09 p.m.