make_hsi: Habitat Suitability Index Generator

Description Usage Arguments Value Examples

View source: R/rrevaluate.r

Description

Generate a habitat suitability index function based on a set of habitat suitability curves and an aggregation rule.

Usage

1
make_hsi(hsc = list(), ag.fun = mean)

Arguments

hsc

A list of habitat suitability curve functions.

ag.fun

A function used for aggregating the outputs of the habitat suitability curves.

Value

A function that calculates the Habitat Suitability Index given a vector or dataframe of habitat suitability parameters corresponding (in order) to the habitat suitability curves contained in hsc.

Examples

1
2
3
4
f1 = make_hsc(c(5, 10, 15, 20, 25), c(0, 0.7, 1, 0.75, 0))
f2 = make_hsc(c(0, 5, 10), c(1, 0.5, 0), scoreleft = 1)
make_hsi(list(f1, f2), ag.fun = mean)
make_hsi(list(f1, f2), ag.fun = min)

mkoohafkan/rremat documentation built on July 3, 2021, 12:06 p.m.