live capture, Conflicting number of occasions

questions concerning anlysis/theory using program DENSITY and R package secr. Focus on spatially-explicit analysis.

live capture, Conflicting number of occasions

Postby bear16 » Thu Jul 18, 2013 12:13 pm

I just started working with a live-capture data set for which each trap was open for ~20 days (and am using the secr package in R). Different sets of traps were open for different time frames within the summer. I set up a file with occasions for the entire time frame (i.e. one occasion per day that at least one trap was open) and just coded traps as closed when they were not in use and open when they were in use.

When I try to read in the capture history, and error message tells me "Conflicting number of occasions in usage matrix". It looks like the numbers correspond to the range of time in which animals were actually captured, but does not account for the number of days during which traps were open on either end of the time frame when traps were open but no animals were caught. I could delete the days on either end during which no animals were caught to rectify the discrepancy in number of occasions, but I am concerned that it would impact trap effort.

Any suggestions?

Thank you!
bear16
 
Posts: 20
Joined: Thu Oct 14, 2010 11:18 am

Re: live capture, Conflicting number of occasions

Postby murray.efford » Thu Jul 18, 2013 4:40 pm

We don't really have enough information. The message comes from the verify function, called automatically by read.capthist and elsewhere. Occasions should be numbered in your capture file from 1 to S where S is the number of 'usage' columns in the trap file. Assuming you are using read.capthist, it may help to specify noccasions = S, whatever S is, although it is intended that read.capthist defaults to the number of usage columns in your trap file if usage is provided. Otherwise, check your data and, if that fails, post more complete information here (clips of data, and code).
Murray
murray.efford
 
Posts: 712
Joined: Mon Sep 29, 2008 7:11 pm
Location: Dunedin, New Zealand

Re: live capture, Conflicting number of occasions

Postby bear16 » Mon Jul 22, 2013 12:59 pm

Thank you. With that suggestion and re-reading that section of the manual, it is now working.

Sorry for the lack of clarity. It was read.caphist.

In case it may be useful to others, the code that ran correctly was:

model1 <- read.capthist('caphist1.txt', trapfile = c('1traploc.txt', '2traploc.txt', '3traploc.txt'), noccasions=c(107, 90, 62), detector = 'single', fmt="trapID", covnames = c("sex"), verify = TRUE)
bear16
 
Posts: 20
Joined: Thu Oct 14, 2010 11:18 am

Re: live capture, Conflicting number of occasions

Postby murray.efford » Mon Jul 22, 2013 4:25 pm

I'm glad you got it working. Was it necessary to specify noccasions despite having the correct usage fields in each trap file? If so, I had better run some tests.
Murray
murray.efford
 
Posts: 712
Joined: Mon Sep 29, 2008 7:11 pm
Location: Dunedin, New Zealand

Re: live capture, Conflicting number of occasions

Postby bear16 » Tue Jul 23, 2013 5:38 pm

In terms of the usage fields, do you mean the correct number of zeroes and ones that code for open or closed?

If so, I have checked a number of times to try to make sure there are no errors, especially because there are so many occasions. I have not found any missing and did need to include the noccasions to get the data to read in correctly.

Thank you.
bear16
 
Posts: 20
Joined: Thu Oct 14, 2010 11:18 am

Re: live capture, Conflicting number of occasions

Postby murray.efford » Tue Jul 23, 2013 8:41 pm

I was able to reproduce the problem and will fix it in the next release. Meantime, specify the number of occasions in each session with noccasions, and check a summary of the input.

Thanks for pointing this out.
Murray
murray.efford
 
Posts: 712
Joined: Mon Sep 29, 2008 7:11 pm
Location: Dunedin, New Zealand


Return to analysis help

Who is online

Users browsing this forum: No registered users and 1 guest