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

add cmdstanr and make stan code more efficient #3

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

spinkney
Copy link

@spinkney spinkney commented Jul 7, 2022

Not sure which version of rstan you're using. This will work with anything after 2.23. I've added cmdstanr so you can test the latest version of Stan at 2.30.

Your code runs on my machine in ~9s with the updates it takes about 2s.

@spinkney
Copy link
Author

spinkney commented Jul 7, 2022

I just saw the comments in the other issue about not caring about efficiency. I think in this case it's a matter of knowing functions and reading the manual, which I think a naive Stan user is likely to do. Anyway, it's just knowing about the bernoulli_logit_glm function. I hope it's not too "expert".

We can remove that function and call bernoulli_logit (no _glm) to be equivalent to what the Stan user's guide has. I think that may be where a new user would copy code from. https://mc-stan.org/docs/stan-users-guide/logistic-probit-regression.html

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant