Differences in design data for S and p with Robust Design

posts related to the RMark library, which may not be of general interest to users of 'classic' MARK

Differences in design data for S and p with Robust Design

Postby WiPhi » Mon Apr 04, 2016 7:37 pm

Hello,
This is my first post to phidot.org and I have found the forum to be very useful for fleshing out Rmark's capabilities. I am hoping you might be able to help with something I encounter when I attempt to use the Robust Design model to estimate survival using for cats marked at all different ages and monitored for several years. I am confident I am correctly identifying my time intervals and I can successfully fit many models using this approach. However, modeling the effects of age on detection probability eludes me.

After specifying groups in process.data based on gender and age at first detection (in integer years), and then making the design data (with make.design.data), I see that the design data for S shows columns for age (both continuous and factor forms) as well as an initial.age.class that allowing me to create new design data based on binning of age into four groups. However the design data for p shows only the initial.age.class and not columns for age (or Age), preventing me from binning in a similar fashion. It is not immediately clear why the design data for p lacks columns for age (cohort is missing as well) while the design data for S does include age and cohort columns.
Thanks for any assistance you can provide.
WiPhi
 
Posts: 27
Joined: Thu Mar 31, 2016 6:15 pm

Re: Differences in design data for S and p with Robust Desig

Postby jlaake » Tue Apr 05, 2016 9:09 am

S is a primary occasion parameter whereas p is a secondary occasion parameter. Been awhile since I've looked at it but I think the code in make.design.data must not be setup to assign age and cohort for secondary occasion parameters. That doesn't mean that you can't do it. As it says somewhere in the documentation, make.design.data provides some default design data but that is only a beginning. When I initially wrote RMark it was for CJS models which only has primary occasions. You can add whatever additional data you want. Since you have initial.age.class in design data for p, write some code that adds an age field using initial.age and change in session with time.intervals between sessions if different than 1. I'll think about adding code for this into make.design.data at some point.

--jeff
jlaake
 
Posts: 1479
Joined: Fri May 12, 2006 12:50 pm
Location: Escondido, CA

Re: Differences in design data for S and p with Robust Desig

Postby WiPhi » Fri Apr 08, 2016 2:48 pm

Thanks Jeff,
Conceptually, your response makes perfect sense, but it may take me a few attempts to implement. My thinking is that I will first need to add another grouping variable for the capture cohort (time at first detection), along with sex and initial age, at the process.data step.
It seems this initial step may be necessary before I can add an age.class column to the design data for p. The number of rows in my default design data for p is the product of nocc, nocc.secondary, and groups (again groups here defined by gender and initial.age). Allowing for groups to age in the design data would require the number of rows being equal to the product of the triangle number of nocc, nocc.secondary, and groups. In my particular case (7 primary occasions) this is 21 times as many rows as I currently have in the p design data.
Take care in reading my posts when I refer to ‘time’. The column names for the primary occasion in the design data for S are ‘time’ and ‘Time’, however those same variables refer to secondary sessions in the design data for p. Took me a while to realize that and the R help file for ‘robust’ made much more sense after figuring that out (‘time’ is use in modelling examples for p and S but referring to very different effects).
Thanks again for a great utility and forum! :)
WiPhi
 
Posts: 27
Joined: Thu Mar 31, 2016 6:15 pm

Re: Differences in design data for S and p with Robust Desig

Postby jlaake » Sat Apr 09, 2016 9:59 am

Since this is closed within a primary occasion, technically animals don't age because the time.intervals are 0 but if the time between secondary occasions is not short then you can adjust for that. If you want cohort then add it to the data and use as a grouping variable. Then you can create your age variable from cohort, session and initial.age. You'll also need to use time.intervals if they are not 1 between primary occasions.

Alternatively, if you don't need cohort, simply redefine your initial age value to be the age at first primary occasion (some may be negative) and then you can simply add session and initial.age to get age. You may want to change any negative ages to 0. I've not used the robust design much but it seems like you'll need to be careful on how you model the age effect here on p.

Yes time for secondary occasion is time within primary occasion whereas session is for the primary occasion.

Hope this helps.
jlaake
 
Posts: 1479
Joined: Fri May 12, 2006 12:50 pm
Location: Escondido, CA

Re: Differences in design data for S and p with Robust Desig

Postby WiPhi » Tue May 17, 2016 1:22 pm

Just wanted to follow up on this. The age from first primary occasion + session seems like a very convenient fix. Further reading suggests this fix may only work in certain model frameworks. From G. Whites Mark Page: "Individual Covariates can be used to model the parameters S, gamma'', and gamma' in the Robust Design data type. Individual Covariates cannot be used with the Robust Design data type for the p's, c's, and N's with the closed capture models that include N because animals that were never captured (and hence, whose individual covariates could never be measured) are incorporated into the likelihood as part of the estimate of population size (N)." Individual covariates can be used in models that allow for individual heterogeneity such as the Huggins models. I will try to update on my success (1) or failure (0) :)
WiPhi
 
Posts: 27
Joined: Thu Mar 31, 2016 6:15 pm


Return to RMark

Who is online

Users browsing this forum: No registered users and 0 guests

cron