Description Usage Arguments Details Author(s) References See Also Examples
this function is used to characterize species' dispersal across the patches for each time step
1 | dispersal(spvector, initp,dismat, allee = 1)
|
spvector |
species-patch abundance matrix prior to dispersal in this time step |
initp |
initial population size for a species that will be released at the source patch at each time step |
dismat |
a dispersal matrix, or connectivity matrix among the patches (i.e., matrix is the same for all species). Different from flex.dispersal() function, which is a list of matrices, and allowed different species will have different dispersal rates across patches |
allee |
allee effect for the species, the minimum viable population in a local patch, default=1, indicating that if the population size in a patch for a species is less than 1, then the species will be removed from that patch |
return an updated species-patch abundance matrix at next time step
Youhua Chen <yhchen@zoology.ubc.ca>
Chen YH (2012) coexist: an R package for performing species coexistence modeling and analysis under asymmetric dispersal and fluctuating source-sink dynamics. http://code.google.com/p/coexist.
1 2 3 4 5 6 7 8 9 10 11 12 13 | ##---- Should be DIRECTLY executable !! ----
##-- ==> Define data, use random,
##-- or do help(data=index) for the standard data sets.
## The function is currently defined as
function (spvector, initp, dismat, allee = 1)
{
spvector <- spvector %*% dismat
spvector[1, 1] = initp
spvector[2, 1] = initp
spvector[which(spvector < allee)] = 0
return(spvector)
}
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.