Become an expert in R — Interactive courses, Cheat Sheets, certificates and more!
Get Started for Free

covariates

Covariates Attribute


Description

Extract or replace covariates

Usage

covariates(object, ...)
covariates(object) <- value

Arguments

object

an object of class traps, popn, capthist, or mask

value

a dataframe of covariates

...

other arguments (not used)

Details

For replacement, the number of rows of value must match exactly the number of rows in object.

Value

covariates(object) returns the dataframe of covariates associated with object. covariates(object) may be NULL.

Individual covariates are stored in the ‘covariates’ attribute of a capthist object.

Covariates used for modelling density are stored in the ‘covariates’ attribute of a mask object.

Detector covariates may vary between sampling occasions. In this case, columns in the detector covariates data.frame are associated with particular times; the matching is controlled by the timevaryingcov attribute.

See Also

Examples

## detector covariates
temptrap <- make.grid(nx = 6, ny = 8)
covariates (temptrap) <- data.frame(halfnhalf = 
    factor(rep(c("left","right"),c(24,24))) )
summary(covariates(temptrap))

secr

Spatially Explicit Capture-Recapture

v4.4.1
GPL (>= 2)
Authors
Murray Efford
Initial release
2021-05-01

We don't support your browser anymore

Please choose more modern alternatives, such as Google Chrome or Mozilla Firefox.