Page 1 of 1
groups='sex' and D~1

Posted:
Wed Oct 16, 2013 4:21 pm
by sixtystrat
Sorry but I’m still hung up on this.
Does it make any sense to model D~1, g0~1, sigma~1 when there is a groups variable (groups=’sex’)? My question is how does secr estimate the densities to be the same for each sex even though the number of animals captured of each sex is different? How much faith should I put in a model with no sex effect on D based on the above scenario?
Thanks!
Joe
Re: groups='sex' and D~1

Posted:
Wed Oct 16, 2013 4:47 pm
by murray.efford
Joe
You have too much choice! I use groups so rarely in secr.fit that I may have forgotten some of the detail, but:
1. Yes, if you specify D~1 in a full model with groups specified then you are requiring density to be the same in both groups. You do have the option of D~g, after all.
2. You can get sex-specific densities based on the actual number for each sex by specifying the groups argument in derived(), after first fitting a model with CL = T or CL = F. This is a completely different mechanism than groups in secr.fit - partitioning by sex only happens at the end. e.g.,
- Code: Select all
derived(ovenbird.model.1, groups='Sex')
3. I prefer myself to use the hcov argument in secr.fit to estimate both the total density and the sex ratio (pmix). e.g.,
- Code: Select all
secr.fit(housemouse, buffer=20, hcov='sex')
...
Fitted (real) parameters evaluated at base levels of covariates
session = coulombe, h2 = f
link estimate SE.estimate lcl ucl
D log 1.223132e+03 96.015316422 1.048955e+03 1.426230e+03
g0 logit 5.415499e-02 0.003520906 4.765443e-02 6.148504e-02
sigma log 3.820084e+00 0.110913844 3.608810e+00 4.043727e+00
pmix logit 4.970796e-01 0.038235311 4.227605e-01 5.715279e-01
session = coulombe, h2 = m
link estimate SE.estimate lcl ucl
D log 1.223132e+03 96.015316422 1.048955e+03 1.426230e+03
g0 logit 5.415499e-02 0.003520906 4.765443e-02 6.148504e-02
sigma log 3.820084e+00 0.110913844 3.608810e+00 4.043727e+00
pmix logit 5.029204e-01 0.038235311 4.284721e-01 5.772395e-01
This is a tidy method that works for both CL = T and CL = F. To model a sex effect on g0 or sigma use h2 in the formula .
Hope this helps
Murray
Re: groups='sex' and D~1

Posted:
Thu Oct 17, 2013 9:00 am
by sixtystrat
Thanks Murray. I could not find any documentation under secr.fit that mentions hcov. Is that a Huggins type of heterogeneity model with sex as the covariate? If you specify that as D~h2 does that negate any kind of mixture model? I could not get it to run (says unused arguments (hov="sex").
Anyway, I assume the estimates will be the same except that now I've lost the mixture model if my assumptions about the Huggins model are correct.
I guess what I am really wondering is, with the groups='sex' option, if the D~1 model has the lower AIC value, should I report that the estimated densities are be equal by sex and the sex ratio is 1:1? The estimate seems forced given that M is different by sex. The D~g models give reasonable sex specific estimates but are less supported by AIC so I assume there is little data to suggest that they really are different. I presume I will run into the same issues reformulating things as you have suggested...?
Re: groups='sex' and D~1

Posted:
Thu Oct 17, 2013 3:49 pm
by murray.efford
hcov is under-documented - I've been wondering if it needs a paper on its own. For now, see the section in the finite mixtures pdf. I'll try to do better in a new version of secr soon. It has nothing to do with Huggins-type models (that is the CL = TRUE option). You need to type 'hcov' not 'hov'.
One attraction of hcov is that it gives you a direct estimate of the sex ratio with a confidence interval. This will take into account sex differences in detection parameters, if these have been modelled. Otherwise it is simply the binomial proportion in your sample.
Murray
Re: groups='sex' and D~1

Posted:
Fri Oct 18, 2013 9:36 am
by sixtystrat
Okay, good to know. Thanks.
Re: groups='sex' and D~1

Posted:
Fri Oct 18, 2013 2:24 pm
by sixtystrat
I thought about it some more so therefore became confused...
What would be the equivalent model to (D~1, g0~1, sigma~t+h2), groups="sex" but using the hcov option?
I ran (D~1, g0~1, sigma~t+h2), hcov="sex" and got different results, I assume because I constrained the mixtures to be sex rather than letting the model figure it out on its own. Is there a way to make an equivalent model where there is a mixture effect for each sex?
Re: groups='sex' and D~1

Posted:
Wed Oct 23, 2013 5:22 am
by murray.efford
If I understand you right, I think the answer is No. By declaring hcov='sex' you constrain the (no longer latent) classes to be sexes, and there is no mechanism for nesting another level of finite mixture within sexes. But do you really want to do that, have you got the data to support it? Also: it may be a mistake not to allow for sex differences in g0.
Murray
Re: groups='sex' and D~1

Posted:
Wed Oct 23, 2013 2:39 pm
by sixtystrat
I think there is some logic for using such a model. In bears, capture probabilities are clearly different by sex. Within the female group, I suspect that females with cubs have lower g0 than those without cubs. At least that was my thinking...
Re: groups='sex' and D~1

Posted:
Wed Oct 23, 2013 5:14 pm
by murray.efford
I agree about the biology, but I suspect you're well into the region of diminishing returns as far as modelling goes, given the data. If you want you can always split the dataset by sex and fit an h2 model within sex (cf Eric Howe's work on female black bears). Or forget about sex as a predictor and simply rely on overall h2. This is tangled up with the issue of compensatory heterogeneity, on which I'll say more later.
Murray