Hi,
I have run into some problems with my model. It's a data set of American black bears hair snagged over a summer using baited detectors. This was divided into 4 occasions. Each occasion lasted 12 days except the 4th, which ran 22 days. I specified that in the Detection location text file as:
#Detector X Y Effort
5 497786 5379253 12 12 12 22
6 500922 5379112 12 12 12 22
#
We are interested in obtain density estimates for male and female bears, so we divided the capture histories as such.
Our study area was also a peninsula, so bears could walk off our trapping area on only 1 narrow stretch. The rest of the study area was bounded by lakes.
We built a habitat mask using the following code:
#
female.mask=make.mask(femaletrap,type="polygon",poly=Voya[],check.poly=T)
#
where femaletrap was the female traps object (using code: traps(femalecapthist)) and Voya is our shapefile (read in using readShapePoly)
Earlier we were specifying a buffer in the make.mask object, but now realize that we don't need this.
When we plotted the mask it seemed like all the mask points were nicely distributed over the land area excluding the water.
We then tried to run a null model with the following code:
#
null.f=secr.fit(females,mask=female.mask,CL=F)
#
But got the following warnings:
1: In secr.fit(females, mask = female.mask, CL = F) :
possible maximization error: nlm returned code 3. See ?nlm
2: In secr.fit(females, mask = female.mask, CL = F) :
at least one variance calculation failed
We also attempted detection as a function of time with the following code:
#
t.f=secr.fit(females,g0~t,mask=female.mask,CL=F)
#
But the following warning was given:
In secr.fit(females, g0 ~ t, mask = female.mask, CL = F) :
possible maximization error: nlm returned code 3. See ?nlm
We have run our data for males using the same code and mask and seem to have no issues.
I would be grateful for any information/help/material you could provide.
Roshan.