Total (class) edge (Area and Edge metric)

## Usage

lsm_c_te(landscape, count_boundary = FALSE, directions = 8)

## Arguments

landscape

Raster* Layer, Stack, Brick, SpatRaster (terra), stars, or a list of rasterLayers.

count_boundary

Include landscape boundary in edge length

directions

The number of directions in which patches should be connected: 4 (rook's case) or 8 (queen's case).

tibble

## Details

$$TE = \sum \limits_{k = 1}^{m} e_{ik}$$ where $$e_{ik}$$ is the edge lengths in meters. TE is an 'Area and edge metric'. Total (class) edge includes all edges between class i and all other classes k. It measures the configuration of the landscape because a highly fragmented landscape will have many edges. However, total edge is an absolute measure, making comparisons among landscapes with different total areas difficult. If cound_boundary = TRUE also edges to the landscape boundary are included.

Meters

TE >= 0

### Behaviour

Equals TE = 0 if all cells are edge cells. Increases, without limit, as landscape becomes more fragmented

## References

McGarigal, K., SA Cushman, and E Ene. 2012. FRAGSTATS v4: Spatial Pattern Analysis Program for Categorical and Continuous Maps. Computer software program produced by the authors at the University of Massachusetts, Amherst. Available at the following web site: http://www.umass.edu/landeco/research/fragstats/fragstats.html

lsm_p_perim lsm_l_te

## Examples

lsm_c_te(landscape)
#> # A tibble: 3 × 6
#>   layer level class    id metric value
#>   <int> <chr> <int> <int> <chr>  <dbl>
#> 1     1 class     1    NA te       180
#> 2     1 class     2    NA te       227
#> 3     1 class     3    NA te       321