Hi ,
I run into a curious problem.
I've tried to run the following model:
secr.fit(MesicBrown2011,model=list(D~session,g0~session+b,sigma~session),buffer=100,detectfn=0,trace=TRUE)
But I get
Checking data
Preparing detection design matrices
Preparing density design matrix
Finding initial parameter values...
Initial values D = 7.80193, g0 = 0.04695, sigma = 17.98337
Maximizing likelihood...
Eval Loglik D D.sessionLG1PP2 D.sessionLG1PP3 g0 g0.sessionLG1PP2 g0.sessionLG1PP3 g0.b sigma sigma.sessionLG1PP2 sigma.sessionLG1PP3
1 NA 2.0544 0.0000 0.0000 -3.0105 0.0000 0.0000 0.0000 2.8894 0.0000 0.0000
2 NA 2.0544 0.0000 0.0000 -3.0105 0.0000 0.0000 0.0000 2.8894 0.0000 0.0000
3 NA 2.0544 0.0000 0.0000 -3.0105 0.0000 0.0000 0.0000 2.8894 0.0000 0.0000
4 NA 2.0544 0.0000 0.0000 -3.0105 0.0000 0.0000 0.0000 2.8894 0.0000 0.0000
So I've read about this kind of problem and some suggest that it could be du to an animal with crazy movement. In that case I could change the detection function to a exponential (2) to be able to get correct Density estimate !
I've done that and it seems to work ...
Checking data
Preparing detection design matrices
Preparing density design matrix
Finding initial parameter values...
Initial values D = 7.86567, g0 = 0.04802, sigma = 17.7744
Maximizing likelihood...
Eval Loglik D D.sessionLG1PP2 D.sessionLG1PP3 g0 g0.sessionLG1PP2 g0.sessionLG1PP3 g0.b sigma sigma.sessionLG1PP2 sigma.sessionLG1PP3
1 -1447.786 2.0625 0.0000 0.0000 -2.9868 0.0000 0.0000 0.0000 2.8778 0.0000 0.0000
2 -1447.786 2.0625 0.0000 0.0000 -2.9868 0.0000 0.0000 0.0000 2.8778 0.0000 0.0000
3 -1447.786 2.0625 0.0000 0.0000 -2.9868 0.0000 0.0000
I get proper density estimate but I'm not sure the result are ok since I've used halfnormal detection function for the rest of my data (long-term data).
Am I doing this right ?
Thanks a lot !!
Nicolas