How to speed up the computation of spatio-temporal model involving Knorr-Held Type IV interaction

392 views
Skip to first unread message

nsyafia...@gmail.com

unread,
May 22, 2017, 2:09:11 AM5/22/17
to R-inla discussion group
Deal all,

I am facing a problem in obtaining a summary model for spatio-temporal model involving Knorr-Held Type IV interaction.

I used weekly data which is 52weeks altogether and the number of area is 86. It took more than a week for computing and I just  close the program as at the end, it crashed.

My program is okay for monthly data and other type of interaction.

Can someone give me an idea to solve this problem and make the computation quicker? 

Thank you in advance.

INLA help

unread,
May 22, 2017, 3:35:55 AM5/22/17
to nsyafia...@gmail.com, R-inla discussion group, Andrea Ingeborg Riebler, Elias T. Krainski
as far as I recall, this model involves a lot of constraints, and these
are costly when they are more than a few, its O(n*k^2) where k
=#constraints.

an alternative take on the problem, is to make sure that the problem is
proper, and then simply ignore the constraints, but then define 'linear
combinations' to extract the 'correct results'. this is like

a + b_i

where we want to have \sum_i b_i = 0.

run without that constraints, then the estimates of a and b are just
nonsense, since their marginal variance will be huge due to confounding
of a constant. then you 'extract' the posterior of

b_i - \sum_j b_j

which will then be the same, or almost the same [you can adjust the
normalizing constant], but this is in the details... [and does not
really matter]

Andrea.R & Elias.K have done some work in this direction, and I think
for this model. They are cc'ed in this email. You could contact them
for more info.

Best
H


--
Håvard Rue
he...@r-inla.org

Nurul Syafiah Abd Naeeim

unread,
May 22, 2017, 9:34:09 PM5/22/17
to he...@r-inla.org, R-inla discussion group, Andrea Ingeborg Riebler, Elias T. Krainski
Thank you Prof Rue.I will try to contact them

nsyafia...@gmail.com

unread,
May 23, 2017, 1:46:10 AM5/23/17
to R-inla discussion group, nsyafia...@gmail.com, andrea....@math.ntnu.no, eli...@ufpr.br, he...@r-inla.org
Dear Prof Rue,

Is it okay if I use gaussian approximation instead of Laplace and simplified Laplace approximation?

INLA help

unread,
May 23, 2017, 2:26:54 AM5/23/17
to nsyafia...@gmail.com, R-inla discussion group, andrea....@math.ntnu.no, eli...@ufpr.br
On Mon, 2017-05-22 at 22:46 -0700, nsyafia...@gmail.com wrote:
> Dear Prof Rue,
>
> Is it okay if I use gaussian approximation instead of Laplace and
> simplified Laplace approximation?
>

try the default option first (simplified...)
--
Håvard Rue
he...@r-inla.org

Haakon Bakka

unread,
May 23, 2017, 3:03:54 AM5/23/17
to INLA help, nsyafia...@gmail.com, R-inla discussion group, Andrea Ingeborg Riebler, eli...@ufpr.br
If you need speedup, I would recommend setting 
control.inla= list(int.strategy = "eb"),
control.mode=list(restart=T, theta= initial.thetas)

Where you run on a smaller dataset, or look at your previous logfile, to find the initial values.

You could also try to lower the tolerance of the optimizer.

Kind regards,
Haakon



--
You received this message because you are subscribed to the Google Groups "R-inla discussion group" group.
To unsubscribe from this group and stop receiving emails from it, send an email to r-inla-discussion-group+unsub...@googlegroups.com.
To post to this group, send an email to r-inla-discussion-group@googlegroups.com.

Reply all
Reply to author
Forward
0 new messages