data (secrdemo)
## construct a traps object from raw trap data
## this dataset uses fmt = 'XY' (x-y coordinates included in
## both trap and capture files), but fmt = 'trapID' (capture file
## uses trap identifier) is simpler
temptrap <- read.traps(data = trapXY, detector = 'single')
plot(temptrap)
## construct a capthist object
captdata <- make.capthist(captXY, temptrap, fmt='XY')
plot(captdata, tracks = TRUE)
## display the null model fit, using the print method for secr
secrdemo.0
Run the code above in your browser using DataLab