individual covariates and density estimates

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

individual covariates and density estimates

Postby matobler » Thu Jun 02, 2016 4:43 pm

I am working on a large dataset for Tasmanian devils. For each individual we have the following covariates: sex, age (2 levels), disease (yes/no). There are no missing covariates so I am using the conditional likelihood model to include individual covariates. The highest ranking model includes disease and age as a covariate for g0 and age as a covariate for sigma which makes sense. I then use derived() to estimate group specific densities. As part of the analysis of this dataset we are interested in estimating the true percentage of diseased animals and animals in each age class for each session accounting for differences in capture probability. However, when I look at the density ratios estimated by derived they are the same as he ratios for the captured individuals which is not logical given the difference in capture probability. Is there something I am missing?

Thanks,

Mathias


Code: Select all
secr.res<-secr.fit(capthist=capthist ,model = list(g0~disease+age+Site,sigma~age+Site),sessioncov=sessioncovdata,  buffer=buffer,binomN = 1, detectfn = 'HN',CL=T,start=secr.0)

pred<-derived(secr.res,groups=c("age","disease"))
matobler
 
Posts: 19
Joined: Fri Nov 03, 2006 9:44 pm
Location: Peru

Re: individual covariates and density estimates

Postby murray.efford » Thu Jun 02, 2016 5:46 pm

What do you get for the individual esa? I would expect values specific to the age etc. of each individual.
Code: Select all
esa(secr.res)

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

Re: individual covariates and density estimates

Postby matobler » Fri Jun 03, 2016 1:35 pm

I get the same value for all individuals. Happy to PM you the fitted model. Here the beta estimates:

Code: Select all
Model           :  g0~disease + age + Site sigma~age + Site
Fixed (real)    :  none
Detection fn    :  halfnormal
N parameters    :  21
Log likelihood  :  -29139.45
AIC             :  58320.9
AICc            :  58321.17

Beta parameters (coefficients)
                             beta    SE.beta         lcl         ucl
g0                   -3.582160613 0.08049342 -3.73992481 -3.42439642
g0.diseased2         -0.225717269 0.08174459 -0.38593373 -0.06550081
g0.agea2              0.285463107 0.05881630  0.17018529  0.40074093
g0.SiteBuckland       0.125249027 0.15545455 -0.17943629  0.42993434
g0.SiteFentonbury    -0.257601090 0.09393375 -0.44170786 -0.07349432
g0.SiteGranville      0.802031674 0.10553196  0.59519283  1.00887052
g0.SiteKempton        0.012206715 0.21004628 -0.39947643  0.42388986
g0.SiteNarawntapu     0.007932201 0.09970625 -0.18748845  0.20335286
g0.SiteTakone        -0.042172082 0.10658109 -0.25106719  0.16672302
g0.SiteWoolnorth     -0.854681303 0.10387437 -1.05827133 -0.65109128
g0.Sitewukalina      -0.275843546 0.13557838 -0.54157230 -0.01011479
sigma                 7.344867026 0.04544689  7.25579275  7.43394130
sigma.agea2          -0.136920435 0.03834598 -0.21207718 -0.06176369
sigma.SiteBuckland   -0.121727308 0.08529092 -0.28889444  0.04543982
sigma.SiteFentonbury -0.191380394 0.05450385 -0.29820597 -0.08455482
sigma.SiteGranville  -0.220923898 0.05786884 -0.33434474 -0.10750306
sigma.SiteKempton    -0.066461596 0.12772210 -0.31679232  0.18386913
sigma.SiteNarawntapu  0.583357155 0.07231543  0.44162151  0.72509280
sigma.SiteTakone     -0.087969332 0.05939671 -0.20438474  0.02844608
sigma.SiteWoolnorth   0.643819783 0.07438158  0.49803457  0.78960499
sigma.Sitewukalina    0.234960490 0.10415442  0.03082158  0.43909940


Mathias
matobler
 
Posts: 19
Joined: Fri Nov 03, 2006 9:44 pm
Location: Peru

Re: individual covariates and density estimates

Postby murray.efford » Fri Jun 03, 2016 10:54 pm

Mathias
It's clearly not working as intended. After some pain I think I've found and fixed the bug in esa(), and will send a link to a provisional patched version of secr later when it passes checks. The derived() step should work fine on your existing fitted model, although for 88 sessions even that takes a long time (mine is still running). Thanks for reporting this.
Murray
murray.efford
 
Posts: 686
Joined: Mon Sep 29, 2008 7:11 pm
Location: Dunedin, New Zealand

Re: individual covariates and density estimates

Postby matobler » Mon Jun 06, 2016 6:49 pm

Murray,

thanks a lot for the quick fix. That solved the issue and density rations for the groups are now (slightly) different than the raw ratios.

I appreciate all the effort you are putting into the secr package.

Mathias
matobler
 
Posts: 19
Joined: Fri Nov 03, 2006 9:44 pm
Location: Peru


Return to analysis help

Who is online

Users browsing this forum: No registered users and 13 guests