simPref: simulate data

Description Usage Arguments Details Value See Also

View source: R/simPref.R

Description

simulate data for predator preferences model

Usage

1
simPref(S, T, J, I, lambda, gamma, EM = F)

Arguments

S

number of prey species

T

number of time periods

J

scalar or vector (of length T) number of predators caught at each time

I

scalar or vector (of length T) effective number of traps at each time

lambda

matrix of rates at which predator eats prey species; TxS

gamma

matrix of rates at which prey species is seen in habitat; TxS

EM

boolean specifying test of EM algorithm

Details

Both lambda and gamma must be specified as a matrix with rows indexing time and columns indexing the number of species.

Value

A list consisting of two dataframes, eaten and caught, made specifically for the function predPref.

See Also

predPref


roualdes/spiders documentation built on May 27, 2019, 11:44 p.m.