repRand: repRand

Description Usage Arguments Value

View source: R/nullmodel.R

Description

Convenience funtion to iterate the null model (settle.rand) reps number of times.

Usage

1
repRand(reps, n.individ, hab.mat, A.coef, ...)

Arguments

reps

Number of model runs to simulate (each run conisting of n.individ number of individuals settling)

n.individ

The number of individuals to simulate for a single model run. Passed to settle.rand.

hab.mat

The matrix containing the "grown" habitats enumerated by the strength of preference (e.g., the output from pref.strength, not convert.cell.) Note that which hab.mat to use (i.e., which preference strength to use) is arbitrary for the null model, but the choice must match the A.coef supplied (below). Passed to settle.rand.

A.coef

The habitat preference parameter that matches the hab.mat supplied. This is the "key" that allows the function to interpret each cell of the matrix as either "Habitat A" or "Habitat B". Passed to settle.rand.

...

Additional arguments as necessary.

Value

A list of list, each element of which is the result of a single model run, Within the results of each model run, the first element is the set of coordinates for the settled location of each individual and the 2nd element is the proportion of those indviduals that settled within "Habitat A".


syanco/checkyourself documentation built on Jan. 18, 2021, 4:50 a.m.