simpopn.bvn | R Documentation |
This wrapper for the secr function sim.popn() adds attributes 's2xy' and 'theta')
simpopn.bvn(s2xy = c(300, 300), theta = NULL, ...)
s2xy |
numeric vector of s^2(x) and s^2(y), or function to generate these (see Details) |
theta |
numeric orientation of home range (radians) |
... |
other arguments passed to |
By default all animals receive the same home range (s2xy) attribute values. An alternative is to generate individual values on the fly; this is achieved by providing a function as the argument s2xy. The function should accept a single argument (the number of individuals) and return a 2-column matrix (the values of s2xy, one row per animal).
NULL theta
causes each animal to be assigned a uniform random
orientation.
Negative theta
causes a single common random orientation to be
chosen (all ranges aligned).
Object of class "popn" with additional attributes 's2xy' and 'theta
See plotpopn.bvn
Examples for variable size (up to
9-fold difference in area in that case).
plotpopn.bvn
, sim.popn
tempgrid <- make.grid(detector='proximity') pop <- simpopn.bvn(s2xy=c(225/2,225*2), core = tempgrid, buffer = 100, D = 10) plot(pop) plotpopn.bvn(pop) # random variation rs2xy <- function(N, scale = 225) { matrix(scale * (0.5 + runif(N*2)*2)^2, ncol = 2) } pop <- simpopn.bvn(s2xy = rs2xy, core = tempgrid, buffer = 100, D = 10) plotpopn.bvn(pop)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.