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
Add category x space x survey interactions to model comparison #25
Comments
Think it's going to have to be like:
for the Besag spatial and AR1 temporal interaction. The rest of them have IID parts in so can be made without |
Jeff's repo here could be helpful https://github.com/jeffeaton/inla-sandbox/blob/master/inla-internals.md |
Rather than try to write a manual AR1 x Besag, I think it'll be easier to write a "manual" Besag x IID then use the This could be tested. |
…). Remove max_model_id option and replace with include_interactions #25
Need to fix this bug:
Can be accomplished using |
Crashed at MOZ
|
Based on early model comparison plots, looks to me like the interactions are improving on things slightly: probably worth keeping in model comparison |
|
See https://github.com/jeffeaton/inla-sandbox/blob/c77d854f43a160841ae7172698e7453e96f08f78/inla-internals.R#L164 for additional information about the interactions between BackgroundCurrently, space x survey x category random effects are being implemented via (here is Model 6x which has Besag x IID x IID):
The challenge here is how to get the right sum-to-zero constraints. How to do it with simpler random effectsUsing the default option
then we get the correct sum-to-zero within each category:
What we need for the interactionsWhat is required for the interaction random effects
What I have currently is:
If there are One way to implement this would be to get What's required for each of the interaction models
|
Got this error for 6x:
EDIT: fixed below. |
Jeff suggests to use separate |
There is a discussion on the |
…ion random effects. Add mutate_dummy() (not needed in the end) and check_sum_to_zero() functions #25
I wrote
I believe what I have implemented is close to being correct, but not totally. Going to try running through the countries to look at model fit criteria when using this almost correct interaction term!
Resources for
|
#' BWA errored straight away :'(
#' MOZ crashed on 8x
#' MWI crashed on 5x |
Can you use three options with
R-INLA
'sgroup
option somehow to do this? I guess worst case use the generic to define the space x survey interaction and then put an IID group for category on top of itThe text was updated successfully, but these errors were encountered: