setpars.population: Defining an Animal Population

Description Usage Arguments Details Value See Also Examples

Description

This function returns the information needed to define an animal population in a 'pars.population´ object.

Usage

1
        setpars.population(density.pop, number.groups = 100, size.method = "user", size.values = 1, size.prob = 1, size.min = 1, size.max = 1, size.mean = 1, exposure.method = "user", exposure.min = 1, exposure.max = 1, exposure.values = 1, exposure.prob = 1, exposure.mean = 0.5 * (exposure.min + exposure.max), exposure.shape = 1, type.values = NA, type.prob = 1, adjust.interactive = FALSE)

Arguments

density.pop

object of class 'density.population´.

number.groups

number of animal groups in population.

size.method

method of how animal group sizes are determined. Possible methods are * 'user´ for the user to enter possible group size values and their probabilities, * poisson for Poisson-distributed group sizes.

size.values

vector of possible group size values (only if size.method has been set to user).

size.prob

vector of respective group size possibilities (only if size.method has been set to user).

size.min

lower bound of group size values (only if size.method has been set to poisson).

size.max

upper bound of group size values (only if size.method has been set to poisson).

size.mean

mean group size value (only if size.method has been set to poisson).

exposure.method

method of how group exposure is determined. Possible methods are * user for the user to enter possible group exposure values and their probabilities, * beta for Poisson-distributed group exposure values.

exposure.min

lower bound of group exposure values.

exposure.max

upper bound of group exposure values.

exposure.values

vector of possible group exposure values (only if exposure.method has been set to user).

exposure.prob

vector of respective group exposure possibilities (only if exposure.method has been set to user).

exposure.mean

mean group exposure value (only if exposure.method has been set to beta).

exposure.shape

shape parameter of the used Beta distribution (only if exposure.method has been set to beta).

type.values

vector of possible type properties for animal groups.

type.prob

vector of respective type probabilities.

adjust.interactive

flag that enables interactive adjustment of size.mean, exposure.mean and exposure.shape (only if size.method has been set to poisson or exposure.method has been set to beta).

Details

An animal population within a region is characterised by different animal groups of different sizes, exposures, types and positions. Animal group positions are calculated in two steps. First, animal groups are randomly distributed over the different cells of the region according to the density matrix. Second, the animal groups are randomly distributed within their cells, then assigning them an x- and y-position. The 'pars.population´ object already contains all elementary population parameters as specified by the arguments of the function. However, an object of class 'population´ can only be generated by running the function generate.population. Group size values can either be entered by the user or generated from a Poisson distribution. In the latter case, the parameter of the distribution needs to be specified. This is done by size.mean. The valid interval of the Poisson distribution can be restricted by a lower and upper bound. size.mean does not have to lie inside this interval. The mechanism for group exposure values works similar. High group exposure values mean that the animal group is easy to detect. The distribution used here is the Beta distribution. It requires the parameters exposure.mean and exposure.shape. Via exposure.min and exposure.max the Beta distribution will be linearly transformed so that its density is not only restricted to the interval [0, 1].

Value

Returns an object of class 'pars.population´. This object has to be passed on to the function generate.population as a list with some or all of the following information: density, number.groups, size.method, size.values, size.prob, size.min, size.max, size.lambda, exposure.method, exposure.min, exposure.max, exposure.mean, exposure.values, exposure.prob, exposure.alpha, exposure.beta, type.values, type.prob, parents, created)

See Also

generate.region, generate.density generate.population, summary.population plot.population

Examples

1
2
3
4
5
6
7
8
9
reg <- generate.region(x.length =100, y.width = 50)
dens <- generate.density(reg,nint.x = 100, nint.y = 50, southwest = 1, southeast = 10, northwest = 20)
dens<-add.hotspot(dens, 20,10, 100,10)
dens<-set.stripe(dens, 0,0, 50,70, value = 0, width = 10)

pop.pars<-setpars.population(density.pop = dens, number.groups = 100, size.method = "poisson", 
					size.min = 1, size.max = 5, size.mean = 1, exposure.method = "beta", 
					exposure.min = 2, exposure.max = 10, exposure.mean = 6, exposure.shape = 1) 
summary(pop.pars)

dill/wisp documentation built on May 15, 2019, 8:31 a.m.