MAPI_EstimateHalfwidth: Function MAPI_EstimateHalfwidth

Description Usage Arguments Details Value References Examples

View source: R/MAPI_EstimateHalfwidth.R

Description

This function computes the side length (= halfwidth) of the hexagonal cells. Halfwidth value can be further used to build a MAPI grid.

Usage

1

Arguments

samples

a data.frame with names and geographical coordinates of samples. Column names must be: 'ind', 'x', 'y'. Optional column 'errRad' with an error radius for sample locations (eg. GPS uncertainty). Coordinates must be projected (not latitude/longitude).

crs

coordinate reference system: integer with the EPSG code, or character with proj4string. The coordinates system must be a projection, not latitude/longitude.

beta

A value depending on spatial regularity of sampling: 0.5 for regular sampling, 0.25 for random sampling (Hengl, 2006).

Details

hw = p / sqrt(2.5980) with p = beta * sqrt(A/N), where A is the study area (convex hull of sampling points) and N the number of samples. Parameter beta allows to respect the Nyquist-Shannon sampling theorem depending on sampling regularity.

Value

halfwidth cell value (side length of hexagonal cells).

References

Hengl, T. (2006) Finding the right pixel size. Computers & Geosciences, 32, 1283–1298.

Examples

1
2
3
data(samples)
# Computes hexagonal cell halfwidth for the 'samples' dataset using beta=0.5
hw <- MAPI_EstimateHalfwidth(samples, beta=0.5)

mapi documentation built on Jan. 19, 2022, 5:06 p.m.