rBatt / trawl

Analysis of scientific trawl surveys of bottom-dwelling marine organisms
1 stars 0 forks source link

Rewrite multiyear Stan models in JAGS #108

Closed rBatt closed 8 years ago

rBatt commented 8 years ago

@mpinsky @mtingley --- I'm giving up on Stan. I've had it.

It's slow for testing (even if it gets effective sample size more quickly, it inhibits rapid prototyping), it keeps breaking, I can't model integer parameters, and Morgan doesn't know it so I can't get as much advice when weird things happen.

I will definitely missing Stan's if()else() statements

I'm done. I learned a new language, I polished up my understanding of the models, and I wrote a bunch of code to carefully handle input data.

I'm hoping that writing the JAGS model won't be too bad, especially coming from Stan. The trick, really, will be getting the model and the data to match. I can do it, I'm just hoping it won't take more than a couple days.

I feel relief just writing this issue. Let's just hope that the JAGS model converges etc.

mtingley commented 8 years ago

Well glad to know I can help you out again!

Model should be fairly easy to write. There's lots of ways to do it.

And everything converges with time.

rBatt commented 8 years ago

Yeah I'll draft a model this weekend.

Plummer says they're planning an if() statement: http://sourceforge.net/p/mcmc-jags/discussion/610037/thread/8ff806a8/

That would make my life so much easier ...

But the control flow isn't necessary.

On Fri, Dec 18, 2015 at 9:47 PM, Morgan Tingley notifications@github.com wrote:

Well glad to know I can help you out again!

Model should be fairly easy to write. There's lots of ways to do it.

And everything converges with time.

— Reply to this email directly or view it on GitHub https://github.com/rBatt/trawl/issues/108#issuecomment-165938914.

rBatt commented 8 years ago

@mpinsky @mtingley I've been running 100 iterations on a semi-full EBS data set (33 years, ~250 spp, 74 sites, a few covariates). It's been 14 hours, and hasn't finished.

In my mind, this basically means I won't be able to run this model at all (a month for 5k iterations, assuming that run with 100 iterations finished right now).

What's a guy to do here? Go back to separate years? Collapse the sites into binomial (eck)? Or maybe my model is doing something stupid. IDK.

rBatt commented 8 years ago

Thought: I actually have many covariates, because for the detection submodel year is a categorical predictor.

Things to try:

rBatt commented 8 years ago

The model is written, so I'm closing this.

But the generic problem of computational walls remains a problem for any MSOM model that includes many years of data (lots of data)