reduce

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

reduce

Postby valeria.boron » Tue May 19, 2015 5:31 am

I have been suggested to use the following command before running secr.fit:

capthist <- reduce(capthist, newocc = list(1:74))

where 74 is the number of occasions. I had much faster computation times but also different results for all parameters (D, g0, sigma). I am still unclear when it is appropriate to use "reduce", and what results are the correct ones (results obtained with or without the reduce command).

Thank you in advance
valeria.boron
 
Posts: 7
Joined: Mon Aug 13, 2012 6:34 am

Re: reduce

Postby murray.efford » Tue May 19, 2015 5:43 am

I assume you have camera data recorded as binary proximity data (0 or 1 for each animal on each day at each camera site). As you have used it, the reduce command collapses the binary data down to one occasion, and I think it will still be binary data i.e. you've lost any multiple records of animals at their favoured sites. The way to do it is to change to the 'count' detector type.
Code: Select all
capthist <- reduce(capthist, newocc = list(1:74), outputdetector = 'count')
or just
Code: Select all
capthist <- reduce(capthist, by = 'ALL', outputdetector = 'count')

Then you strictly should call secr.fit with 74 as the known maximum number of daily records:
Code: Select all
secr.fit(capthist, binomN = 74 etc.)

However, the default count model (Poisson) will probably give about the same result.
I hope I've remembered that right! I have noticed minor variation between some collapsed and original analyses, but not so far enough to worry about.
Murray
murray.efford
 
Posts: 712
Joined: Mon Sep 29, 2008 7:11 pm
Location: Dunedin, New Zealand

Re: reduce

Postby valeria.boron » Tue May 19, 2015 8:34 am

Thank you Murray. I do have camera trap data recorded as binary proximity data, as you said.
I re-run the models with your command:

capthist <- reduce(capthist, newocc = list(1:74), outputdetector = 'count')

but I do get some differences: D=3.6 without the reduce command vs D=2.2 with the reduce command, g0 and sigma are also different.

When I allow g0 and sigma to vary with sex of individuals (secr.sex) is the same story, using or not using "reduce" does change D, g0, and sigma especially for males.
Results secr.sex with reduce command:
D=3.0
g0 Males = 0.98 g0 Females=0.037
Sigma Males=1608 Sigma Females =1437

Results secr.sex without reduce command:
D=4.1
g0 Males = 0.11 g0 Females=0.037
Sigma Males=700 Sigma Females =1445

I am guessing I should report the results of the non-collapsed dataset and that generally speaking they are more accurate as "reduce" is an optional step in the analysis; is that right?
if I don' t use "reduce" sigma for males actually becomes half the one of females which doesn't make sense biologically for jaguars but I am just interested in understanding what is the correct approach and how I should run future analysis with similar datasets.

Also in terms of model selection, if AIC and AICc show different trends like here below do you recommend selecting the best model using AIC or AICc?

model detectfn npar logLik AIC AICc dAICc AICcwt
secr.0 D~1 g0~1 sigma~1 pmix~h2 halfnormal 4 -468.3679 944.736 952.736 0.000 0.8590
secr.sex.s D~1 g0~1 sigma~h2 pmix~h2 halfnormal 5 -465.7457 941.491 956.491 3.755 0.1314
secr.sex.g D~1 g0~h2 sigma~1 pmix~h2 halfnormal 5 -468.3638 946.728 961.728 8.992 0.0096
secr.sex D~1 g0~h2 sigma~h2 pmix~h2 halfnormal 6 -463.9369 939.874 967.874 15.138 0.0000

Thanks again
valeria.boron
 
Posts: 7
Joined: Mon Aug 13, 2012 6:34 am

Re: reduce

Postby murray.efford » Tue May 19, 2015 6:02 pm

Hi Valeria

I might be able to diagnose the problem if you send me the dataset offline.

The idea of AICc is to adjust for small sample size, and your samples must be very small for there to be a major difference. Whether AICc is preferable to AIC is somewhat unclear; with very small datasets you cannot trust the model selection results either way. So you see this is not something I personally want to be quoted on! Most people seem to accept Burnham & Anderson's argument that AICc, but there are statisticians who find AIC preferable at least in some circumstances.

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

Re: reduce

Postby valeria.boron » Wed May 20, 2015 5:36 am

Thank you and yes, it is a very small sample size indeed! I just emailed you the data
valeria.boron
 
Posts: 7
Joined: Mon Aug 13, 2012 6:34 am

Re: reduce

Postby murray.efford » Sun May 24, 2015 11:15 pm

Valeria asked why estimates from a 74-day binary 'proximity' dataset changed when the data were collapsed to single-occasion binomial count data. Theoretically they should not change (Efford, Dawson & Borchers 2009).

After playing with Valeria's data I concluded that the problem was numerical. Essentially, model fits can be sensitive to the setting of the details argument 'minprob' in secr.fit. Set this to a small enough value and the estimates become stable. For example
Code: Select all
secr.fit(CH, ..., details = list(minprob = 1e-200))

seems OK, and in future versions I'll make that the default instead of 1e-50 (already fixed in working version on the Density website).

The data collapsed to a single occasion gave the correct answer and the original, uncollapsed analysis was wrong. I suspect it is a problem only with 'extreme' datasets (few animals, many occasions, or, possibly, poor model fit due to unmodelled camera-site effects).

It is possible that other people's analyses have been affected. Always cross check your results! In this case I used some simple R code that calculated the likelihood quite independently of secr.fit(), and I'll look at ways to make that available. I would be interested to hear of other datasets for which the result is sensitive to minprob.

(Incidentally: the likelihoods differ by a constant (the sum of binomial coefficients for each animal x site count) that depends on the data but not the parameter values; certainly the original and collapsed models should not be compared by AIC).

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

cron