Skip to content
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

Rewrite multiyear Stan models in JAGS #108

Closed
rBatt opened this issue Dec 19, 2015 · 5 comments
Closed

Rewrite multiyear Stan models in JAGS #108

rBatt opened this issue Dec 19, 2015 · 5 comments
Assignees
Labels

Comments

@rBatt
Copy link
Owner

rBatt commented Dec 19, 2015

@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
Copy link
Collaborator

mtingley commented Dec 19, 2015 via email

@rBatt
Copy link
Owner Author

rBatt commented Dec 19, 2015

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
#108 (comment).

rBatt added a commit that referenced this issue Dec 19, 2015
rBatt added a commit that referenced this issue Dec 20, 2015
rBatt referenced this issue Dec 20, 2015
@mtingley I still intend to write out those equations, but I put a pretty thorough set of definitions at the top of this model file, and at the end of those top comments is a brief equation summary
@rBatt rBatt self-assigned this Dec 20, 2015
rBatt added a commit that referenced this issue Dec 21, 2015
rBatt added a commit that referenced this issue Dec 21, 2015
rBatt added a commit that referenced this issue Dec 21, 2015
@rBatt
Copy link
Owner Author

rBatt commented Dec 22, 2015

@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
Copy link
Owner Author

rBatt commented Dec 22, 2015

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

Things to try:

  • Remove categorical year predictor in dynamic model, run for 100 iterations
  • Try same as above, but in the 'stacked' model
  • If run times for those still seem astronomical, go back to running each year separately

@rBatt
Copy link
Owner Author

rBatt commented Feb 4, 2016

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)

@rBatt rBatt closed this as completed Feb 4, 2016
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants