{"id":374,"date":"2017-05-06T04:01:31","date_gmt":"2017-05-06T04:01:31","guid":{"rendered":"http:\/\/sites.warnercnr.colostate.edu\/gwhite\/?page_id=374"},"modified":"2017-05-06T04:01:31","modified_gmt":"2017-05-06T04:01:31","slug":"individual-covariates-basic","status":"publish","type":"page","link":"https:\/\/sites.warnercnr.colostate.edu\/gwhite\/individual-covariates-basic\/","title":{"rendered":"Individual Covariates Basic"},"content":{"rendered":"<p><span style=\"color: #0000ff;font-family: Arial, helvetica, sans-serif;font-size: small\"><a href=\"http:\/\/oldweb.warnercnr.colostate.edu\/~gwhite\/mark\/markhelp\/index.html\">Contents<\/a> &#8211; <a href=\"http:\/\/oldweb.warnercnr.colostate.edu\/~gwhite\/mark\/markhelp\/idx.htm\">Index<\/a><\/span><\/p>\n<hr \/>\n<p><span style=\"color: #0000ff;font-family: Arial, helvetica, sans-serif;font-size: small\">Individual covariates are entered into Program MARK via the <a href=\"http:\/\/oldweb.warnercnr.colostate.edu\/~gwhite\/mark\/markhelp\/encounter_histories_file.htm\">Encounter Histories File<\/a>.\u00a0 These values follow the number of animals encountered for the encounter history, as described in the <a href=\"http:\/\/oldweb.warnercnr.colostate.edu\/~gwhite\/mark\/markhelp\/encounter_histories_format.htm\">Encounter Histories Format<\/a>.\u00a0 Individual covariates are used to incorporate information specific to the individual into the parameter estimate.\u00a0 Individual covariates are <a>named<\/a> when the number of individual covariates is specified during the <a href=\"http:\/\/oldweb.warnercnr.colostate.edu\/~gwhite\/mark\/markhelp\/initial_values.htm\">Initial Values<\/a> screen.<\/span><\/p>\n<p><span style=\"color: #0000ff;font-family: Arial, helvetica, sans-serif;font-size: small\">Individual covariates are not allowed to have missing values, because the parameter value for the animal with the missing individual covariate value would also be missing, and henced the animal could not contribute to the likelihood.\u00a0 Several <a href=\"http:\/\/oldweb.warnercnr.colostate.edu\/~gwhite\/mark\/markhelp\/individual_covariates_missing_values.htm\">options<\/a> for handling individual covariates are available.<\/span><\/p>\n<p><span style=\"color: #0000ff;font-family: Arial, helvetica, sans-serif;font-size: small\">Interactions of individual covariates can be created with the <a href=\"http:\/\/oldweb.warnercnr.colostate.edu\/~gwhite\/mark\/markhelp\/design_matrix_functions.htm\">product function<\/a>.<\/span><\/p>\n<p><span style=\"color: #0000ff;font-family: Arial, helvetica, sans-serif;font-size: small\">By specifying the name of an individual covariate in a cell of the <a href=\"http:\/\/oldweb.warnercnr.colostate.edu\/~gwhite\/mark\/markhelp\/design_matrix.htm\">Design Matrix<\/a>, you tell MARK to use the value of this covariate in the design matrix when the capture history for this individual is used in the likelihood.\u00a0 As an example, suppose that 2 individual covariates are included in the : age (0=subadult, 1=adult), and weight at time of initial capture.\u00a0 The variable names given to these variables are, naturally, AGE and WEIGHT.\u00a0 Their are 8 survival rates in a known fate analysis.\u00a0 The following design matrix would use weight as a covariate, with an intercept term.<\/span><br \/>\n<span style=\"color: #0000ff;font-family: Arial, helvetica, sans-serif;font-size: small\">1\u00a0 weight\u00a0<\/span><br \/>\n<span style=\"color: #0000ff;font-family: Arial, helvetica, sans-serif;font-size: small\">1\u00a0 weight\u00a0<\/span><br \/>\n<span style=\"color: #0000ff;font-family: Arial, helvetica, sans-serif;font-size: small\">1\u00a0 weight\u00a0<\/span><br \/>\n<span style=\"color: #0000ff;font-family: Arial, helvetica, sans-serif;font-size: small\">1\u00a0 weight\u00a0<\/span><br \/>\n<span style=\"color: #0000ff;font-family: Arial, helvetica, sans-serif;font-size: small\">1\u00a0 weight\u00a0<\/span><br \/>\n<span style=\"color: #0000ff;font-family: Arial, helvetica, sans-serif;font-size: small\">1\u00a0 weight\u00a0<\/span><br \/>\n<span style=\"color: #0000ff;font-family: Arial, helvetica, sans-serif;font-size: small\">1\u00a0 weight\u00a0<\/span><br \/>\n<span style=\"color: #0000ff;font-family: Arial, helvetica, sans-serif;font-size: small\">1\u00a0 weight\u00a0<\/span><\/p>\n<p><span style=\"color: #0000ff;font-family: Arial, helvetica, sans-serif;font-size: small\">Each of the 8 time-specific survival rates would be modeled with the same model.\u00a0 Thus, time is not included in the relationship.\u00a0 Suppose you believe that the relationship between survival and weight changes with each time interval.\u00a0 The following design matrix would allow 8 different weight models.<\/span><br \/>\n<span style=\"color: #0000ff;font-family: Arial, helvetica, sans-serif;font-size: small\">1\u00a0 weight\u00a0 0\u00a0 0\u00a0 0\u00a0 0\u00a0 0\u00a0 0\u00a0 0\u00a0 0\u00a0 0 0\u00a0 0\u00a0 0\u00a0 0\u00a0 0\u00a0<\/span><br \/>\n<span style=\"color: #0000ff;font-family: Arial, helvetica, sans-serif;font-size: small\">0\u00a0 0\u00a0 1\u00a0 weight\u00a0 0\u00a0 0\u00a0 0\u00a0 0\u00a0 0\u00a0 0\u00a0 0 0\u00a0 0\u00a0 0\u00a0 0\u00a0 0\u00a0<\/span><br \/>\n<span style=\"color: #0000ff;font-family: Arial, helvetica, sans-serif;font-size: small\">0\u00a0 0\u00a0 0\u00a0 0\u00a0 1\u00a0 weight\u00a0 0\u00a0 0\u00a0 0\u00a0 0\u00a0 0 0\u00a0 0\u00a0 0\u00a0 0\u00a0 0\u00a0<\/span><br \/>\n<span style=\"color: #0000ff;font-family: Arial, helvetica, sans-serif;font-size: small\">0\u00a0 0\u00a0 0\u00a0 0\u00a0 0\u00a0 0\u00a0 1\u00a0 weight\u00a0 0\u00a0 0\u00a0 0 0\u00a0 0\u00a0 0\u00a0 0\u00a0 0\u00a0<\/span><br \/>\n<span style=\"color: #0000ff;font-family: Arial, helvetica, sans-serif;font-size: small\">0\u00a0 0\u00a0 0\u00a0 0\u00a0 0\u00a0 0\u00a0 0\u00a0 0\u00a0 1\u00a0 weight\u00a0 0 0\u00a0 0\u00a0 0\u00a0 0\u00a0 0\u00a0<\/span><br \/>\n<span style=\"color: #0000ff;font-family: Arial, helvetica, sans-serif;font-size: small\">0\u00a0 0\u00a0 0\u00a0 0\u00a0 0\u00a0 0\u00a0 0\u00a0 0\u00a0 0\u00a0 0\u00a0 1\u00a0 weight\u00a0 0\u00a0 0\u00a0 0\u00a0 0\u00a0<\/span><br \/>\n<span style=\"color: #0000ff;font-family: Arial, helvetica, sans-serif;font-size: small\">0\u00a0 0\u00a0 0\u00a0 0\u00a0 0\u00a0 0\u00a0 0\u00a0 0\u00a0 0\u00a0 0\u00a0 0\u00a0 0 1\u00a0 weight\u00a0 0\u00a0 0\u00a0<\/span><br \/>\n<span style=\"color: #0000ff;font-family: Arial, helvetica, sans-serif;font-size: small\">0\u00a0 0\u00a0 0\u00a0 0\u00a0 0\u00a0 0\u00a0 0\u00a0 0\u00a0 0\u00a0 0\u00a0 0\u00a0 0 0\u00a0 0\u00a0 1\u00a0 weight\u00a0<\/span><\/p>\n<p><span style=\"color: #0000ff;font-family: Arial, helvetica, sans-serif;font-size: small\">The following model would have a common intercept for each\u00a0 survival rate, but different slopes for the weight variable.<\/span><br \/>\n<span style=\"color: #0000ff;font-family: Arial, helvetica, sans-serif;font-size: small\">1\u00a0 weight\u00a0 0\u00a0 0\u00a0 0\u00a0 0\u00a0 0\u00a0 0\u00a0 0\u00a0<\/span><br \/>\n<span style=\"color: #0000ff;font-family: Arial, helvetica, sans-serif;font-size: small\">1\u00a0 0\u00a0 weight\u00a0 0\u00a0 0\u00a0 0\u00a0 0\u00a0 0\u00a0 0\u00a0<\/span><br \/>\n<span style=\"color: #0000ff;font-family: Arial, helvetica, sans-serif;font-size: small\">1\u00a0 0\u00a0 0\u00a0 weight\u00a0 0\u00a0 0\u00a0 0\u00a0 0\u00a0 0\u00a0<\/span><br \/>\n<span style=\"color: #0000ff;font-family: Arial, helvetica, sans-serif;font-size: small\">1\u00a0 0\u00a0 0\u00a0 0\u00a0 weight\u00a0 0\u00a0 0\u00a0 0\u00a0 0\u00a0<\/span><br \/>\n<span style=\"color: #0000ff;font-family: Arial, helvetica, sans-serif;font-size: small\">1\u00a0 0\u00a0 0\u00a0 0\u00a0 0\u00a0 weight\u00a0 0\u00a0 0\u00a0 0\u00a0<\/span><br \/>\n<span style=\"color: #0000ff;font-family: Arial, helvetica, sans-serif;font-size: small\">1\u00a0 0\u00a0 0\u00a0 0\u00a0 0\u00a0 0\u00a0 weight\u00a0 0\u00a0 0\u00a0<\/span><br \/>\n<span style=\"color: #0000ff;font-family: Arial, helvetica, sans-serif;font-size: small\">1\u00a0 0\u00a0 0\u00a0 0\u00a0 0\u00a0 0\u00a0 0\u00a0 weight\u00a0 0\u00a0<\/span><br \/>\n<span style=\"color: #0000ff;font-family: Arial, helvetica, sans-serif;font-size: small\">1\u00a0 0\u00a0 0\u00a0 0\u00a0 0\u00a0 0\u00a0 0\u00a0 0\u00a0 weight\u00a0<\/span><\/p>\n<p><span style=\"color: #0000ff;font-family: Arial, helvetica, sans-serif;font-size: small\">The <a>Copy Value<\/a> is useful for creating these design matrices, as well as <a href=\"http:\/\/oldweb.warnercnr.colostate.edu\/~gwhite\/mark\/markhelp\/save_design_matrix.htm\">Saving<\/a> the design matrix to a file, editing in a spreadsheet, and copying the new design matrix to the clipboard, and then <a href=\"http:\/\/oldweb.warnercnr.colostate.edu\/~gwhite\/mark\/markhelp\/paste_clipboard_design_matrix.htm\">Pasting<\/a> the clipboard back into the design matrix.<\/span><\/p>\n<p><span style=\"color: #0000ff;font-family: Arial, helvetica, sans-serif;font-size: small\">Note that models with individual covariates have a different set of real parameter estimates for each animal.\u00a0 To compute the real parameter estimates, 3 options are available from the <a href=\"http:\/\/oldweb.warnercnr.colostate.edu\/~gwhite\/mark\/markhelp\/run_window.htm\">Run Window<\/a>.\u00a0 More details are provided in the topic discussing the <a href=\"http:\/\/oldweb.warnercnr.colostate.edu\/~gwhite\/mark\/markhelp\/individual_covariates_and_real_estimates.htm\">real parameter estimates from models with individual covariates<\/a>.<\/span><\/p>\n<p><span style=\"color: #0000ff;font-family: Arial, helvetica, sans-serif;font-size: small\"><b>Warning<\/b>\u00a0 If you use the <a>Standardize Individual Covariates<\/a> option of the <a href=\"http:\/\/oldweb.warnercnr.colostate.edu\/~gwhite\/mark\/markhelp\/run_window.htm\">Run Window<\/a> to perform the default standardization method, and then build a model with a 2 different slopes but a common intercepts, e.g.,<\/span><\/p>\n<p><span style=\"color: #0000ff;font-family: Arial, helvetica, sans-serif;font-size: small\">\u00a0 1 weight 0<\/span><br \/>\n<span style=\"color: #0000ff;font-family: Arial, helvetica, sans-serif;font-size: small\">\u00a0 1 0 weight<\/span><\/p>\n<p><span style=\"color: #0000ff;font-family: Arial, helvetica, sans-serif;font-size: small\">you will get different estimates of the beta parameters for the standardized individual covariates than you would get with unstandardized individual covariates unless you use the identity link (which will seldom converge with individual covariates).\u00a0 This problem is because the non-linear link functions available cause the centering of the standardized covariate to affect the intercept differently than if unstandardized covariates were used.\u00a0 For this situation, using the unstandardized covariates is probably the best solution, assuming that you can get your model to converge.<\/span><\/p>\n<p><span style=\"color: #0000ff;font-family: Arial, helvetica, sans-serif;font-size: small\"><b>Time-Varying Individual Covariates<\/b><\/span><\/p>\n<p><span style=\"color: #0000ff;font-family: Arial, helvetica, sans-serif;font-size: small\">You can include time-varying individual covariates in MARK files, but must have a value for every animal on every occasion, even if the animal is not captured.\u00a0 Typically, you can impute these values, but be sure to recognize what this imputation might do to your estimates.\u00a0 You implement time-varying individual covariates just like any other individual covariate, expect that you have to have a different name for each covariate corresponding to each time period.\u00a0 For example, suppose you have a known fate model with 5 occasions, and you have estimated the parasite load for each animal at the beginning of each of the 5 occasions.\u00a0 The 5 values for each animal are contained in the variables var1, var2, var3, var4, and var5.\u00a0 A design matrix that would estimate the effect of the parasite load assuming that the effect is constant across time would be:<\/span><\/p>\n<p><span style=\"color: #0000ff;font-family: Arial, helvetica, sans-serif;font-size: small\">1 var1<\/span><br \/>\n<span style=\"color: #0000ff;font-family: Arial, helvetica, sans-serif;font-size: small\">1 var2<\/span><br \/>\n<span style=\"color: #0000ff;font-family: Arial, helvetica, sans-serif;font-size: small\">1 var3<\/span><br \/>\n<span style=\"color: #0000ff;font-family: Arial, helvetica, sans-serif;font-size: small\">1 var4<\/span><br \/>\n<span style=\"color: #0000ff;font-family: Arial, helvetica, sans-serif;font-size: small\">1 var5<\/span><\/p>\n<p><span style=\"color: #0000ff;font-family: Arial, helvetica, sans-serif;font-size: small\">The second beta estimate is the slope parameter associated with the time-varying individual covariates.\u00a0 Note that you <b>do not<\/b> want to <a>standardize<\/a> these individual covariates, because standardizing them will cause them to no longer relate to one another on the same scale (making a common slope parameter nonsensical).\u00a0 Each would have a different scale after standardizing.\u00a0 If you need to standardize the covariates, you must do so before the values are included in a MARK <a href=\"http:\/\/oldweb.warnercnr.colostate.edu\/~gwhite\/mark\/markhelp\/encounter_histories_file.htm\">encounter histories input file<\/a>, and you must use a common mean and standard deviation across the entire set of variables and observations.<\/span><\/p>\n<p><span style=\"color: #0000ff;font-family: Arial, helvetica, sans-serif;font-size: small\">The following design matrix would build a model where you assume the effect of parasite load is different for each interval, but with the same survival rate for animals with no parasites (i.e., the same intercept).<\/span><br \/>\n<span style=\"color: #0000ff;font-family: Arial, helvetica, sans-serif;font-size: small\">.<\/span><br \/>\n<span style=\"color: #0000ff;font-family: Arial, helvetica, sans-serif;font-size: small\">1 var1 0 0 0 0<\/span><br \/>\n<span style=\"color: #0000ff;font-family: Arial, helvetica, sans-serif;font-size: small\">1 0 var2 0 0 0<\/span><br \/>\n<span style=\"color: #0000ff;font-family: Arial, helvetica, sans-serif;font-size: small\">1 0 0 var3 0 0<\/span><br \/>\n<span style=\"color: #0000ff;font-family: Arial, helvetica, sans-serif;font-size: small\">1 0 0 0 var4 0<\/span><br \/>\n<span style=\"color: #0000ff;font-family: Arial, helvetica, sans-serif;font-size: small\">1 0 0 0 0 var5<\/span><\/p>\n<p><span style=\"color: #0000ff;font-family: Arial, helvetica, sans-serif;font-size: small\">The following model would allow different survival rates for each interval (i.e., time-specific survival), but assumes the same impact of parasites on survival on the logit scale (assuming that a logit link function is used).<\/span><\/p>\n<p><span style=\"color: #0000ff;font-family: Arial, helvetica, sans-serif;font-size: small\">1 1 0 0 0 var1<\/span><br \/>\n<span style=\"color: #0000ff;font-family: Arial, helvetica, sans-serif;font-size: small\">1 0 1 0 0 var2<\/span><br \/>\n<span style=\"color: #0000ff;font-family: Arial, helvetica, sans-serif;font-size: small\">1 0 0 1 0 var3<\/span><br \/>\n<span style=\"color: #0000ff;font-family: Arial, helvetica, sans-serif;font-size: small\">1 0 0 0 1 var4<\/span><br \/>\n<span style=\"color: #0000ff;font-family: Arial, helvetica, sans-serif;font-size: small\">1 0 0 0 0 var5<\/span><\/p>\n<p><span style=\"color: #0000ff;font-family: Arial, helvetica, sans-serif;font-size: small\">Finally, a model like the following would allow a completely different survival rate and parasite effect for each occasion.<\/span><\/p>\n<p><span style=\"color: #0000ff;font-family: Arial, helvetica, sans-serif;font-size: small\">1 1 0 0 0 var1 0 0 0 0<\/span><br \/>\n<span style=\"color: #0000ff;font-family: Arial, helvetica, sans-serif;font-size: small\">1 0 1 0 0 0 var2 0 0 0<\/span><br \/>\n<span style=\"color: #0000ff;font-family: Arial, helvetica, sans-serif;font-size: small\">1 0 0 1 0 0 0 var3 0 0<\/span><br \/>\n<span style=\"color: #0000ff;font-family: Arial, helvetica, sans-serif;font-size: small\">1 0 0 0 1 0 0 0 var4 0<\/span><br \/>\n<span style=\"color: #0000ff;font-family: Arial, helvetica, sans-serif;font-size: small\">1 0 0 0 0 0 0 0 0 var5<\/span><\/p>\n<p><span style=\"color: #0000ff;font-family: Arial, helvetica, sans-serif;font-size: small\">Individual covariates can be used in the <a href=\"http:\/\/oldweb.warnercnr.colostate.edu\/~gwhite\/mark\/markhelp\/design_matrix_functions.htm\">add and product functions<\/a> of the design matrix.<\/span><\/p>\n<p><span style=\"color: #0000ff;font-family: Arial, helvetica, sans-serif;font-size: small\">The value of <a href=\"http:\/\/oldweb.warnercnr.colostate.edu\/~gwhite\/mark\/markhelp\/individual_covariates_and_real_estimates.htm\">individual covariates specified<\/a> at the time the model is run will determine the value of the <a href=\"http:\/\/oldweb.warnercnr.colostate.edu\/~gwhite\/mark\/markhelp\/real_parameter.htm\">real<\/a> and <a href=\"http:\/\/oldweb.warnercnr.colostate.edu\/~gwhite\/mark\/markhelp\/derived_parameters.htm\">derived<\/a> parameter values.\u00a0 Thus, the same values should be used for all models where the real or derived parameters are to be <a href=\"http:\/\/oldweb.warnercnr.colostate.edu\/~gwhite\/mark\/markhelp\/model_averaging.htm\">model averaged<\/a>.<\/span><\/p>\n","protected":false},"excerpt":{"rendered":"<p>Contents &#8211; Index Individual covariates are entered into Program MARK via the Encounter Histories File.\u00a0 These values follow the number of animals encountered for the encounter history, as described in the Encounter Histories Format.\u00a0 Individual covariates are used to incorporate &hellip;<\/p>\n<p class=\"read-more\"> <a class=\"more-link\" href=\"https:\/\/sites.warnercnr.colostate.edu\/gwhite\/individual-covariates-basic\/\"> <span class=\"screen-reader-text\">Individual Covariates Basic<\/span> Read More &raquo;<\/a><\/p>\n","protected":false},"author":117,"featured_media":0,"parent":0,"menu_order":0,"comment_status":"closed","ping_status":"closed","template":"","meta":{"footnotes":""},"class_list":["post-374","page","type-page","status-publish","hentry"],"_links":{"self":[{"href":"https:\/\/sites.warnercnr.colostate.edu\/gwhite\/wp-json\/wp\/v2\/pages\/374","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/sites.warnercnr.colostate.edu\/gwhite\/wp-json\/wp\/v2\/pages"}],"about":[{"href":"https:\/\/sites.warnercnr.colostate.edu\/gwhite\/wp-json\/wp\/v2\/types\/page"}],"author":[{"embeddable":true,"href":"https:\/\/sites.warnercnr.colostate.edu\/gwhite\/wp-json\/wp\/v2\/users\/117"}],"replies":[{"embeddable":true,"href":"https:\/\/sites.warnercnr.colostate.edu\/gwhite\/wp-json\/wp\/v2\/comments?post=374"}],"version-history":[{"count":1,"href":"https:\/\/sites.warnercnr.colostate.edu\/gwhite\/wp-json\/wp\/v2\/pages\/374\/revisions"}],"predecessor-version":[{"id":375,"href":"https:\/\/sites.warnercnr.colostate.edu\/gwhite\/wp-json\/wp\/v2\/pages\/374\/revisions\/375"}],"wp:attachment":[{"href":"https:\/\/sites.warnercnr.colostate.edu\/gwhite\/wp-json\/wp\/v2\/media?parent=374"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}