-
Notifications
You must be signed in to change notification settings - Fork 13
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conf. Int with RSS #64
Comments
Unfortunately, there isn't. You can fit a population-level model using the approach of Muff et al. (). But you would have to calculate the log RSS manually. Maybe @bsmity13 has something to add here? |
Hi @anjankatna. Yes, those CIs represent the uncertainty in the parameter estimates for each individual. The uncertainty in the betas is propagated through to uncertainty in log-RSS. And as @jmsigner said, there's no implementation of an approach with random effects in I would add that you can also use a two-step procedure for population-level inference instead of random effects. I.e., you can treat the individual coefficients as a response variable in a regression, often using inverse-variance weighting ( Here's a very quick example. This is for an HSF, but the same idea works for an iSSF.
Note that the best way to get CIs for log-RSS in this case is bootstrapping. Since you model the coefficients with separate linear models, you aren't estimating the covariance between them, so you can't use just the SEs to construct a confidence interval. Hope the brevity isn't misleading. Happy to answer any follow-up questions. Hope that helps! |
Hello, @bsmity13. I'm asking this question because it has to do with log RSS and confidence intervals. In my study, I calculated the coefficient for population-level inference using the Two-Step technique (iSSF). I was able to manually obtain the log RSS, but I'm struggling as to how to determine the Confidence Interval. Since you indicate that it's better to use bootstrapping to get CI in the Two-Step technique, I will be grateful if you could give a bit of code that demonstrates how to implement it. Thanks in advance. |
Hi, @Imthiazz. Here's a quick demo. I mostly followed the example above through fitting the models. From there, we start with the bootstrap. I am using a parametric bootstrap, where we resample the coefficients from each individual model from a multivariate normal distribution with mean given by the fitted coefficients and Sigma given by the variance-covariance matrix from each model. A similar approach would be possible with some kind of empirical bootstrap where you resample the data with replacement. For each iteration, we calculate the mean population-level coefficient. Notice I dropped the inverse-variance weighting because the bootstrapping will take care of that parametric uncertainty for us. The "statistic of interest" is log-RSS, but we don't have to calculate it inside our function (we could) because it's a deterministic function of the mean coefficient that we are resampling. So that means we can just calculate log-RSS after the bootstrapping is done. Note that the mean of the bootstrap distribution is not the same as the maximum likelihood estimate of log-RSS. We still want to keep our MLE, so we use the bootstrap distribution to estimate the size of the CI, not the actual bounds. Then we apply that size to the MLE to get our confidence interval. Here's the code.
Hope it helps! |
Hi,
I wanted to clarify the significance/interpretation of the CI values in the log_RSS outputs.
My data has movement data from 5 individuals, and I used the nesting function while preparing the data for the SSF analysis.
Do the CI values then represent the individual variation in RSSs?
log_rss lwr upr
1 -0.3016729 -0.9272444 0.3238985
2 0.2160458 -0.1960536 0.6281452
3 -1.5873831 -2.7426228 -0.4321434
4 0.2295385 -0.5318209 0.9908980
5 -12.0790214 -2733.3505573 2709.1925144
The data looks at different landcover classes, with respect to a reference class (grassland)
I am assuming there is no separate method to account if individual-level effects in the amt workflow (e.g. including a random effect)
The text was updated successfully, but these errors were encountered: