Bayes Posterior distribution - proc MCMC

Hello everyone, I'm new to the community and I hope I'm writing in the right place.
I need help to translate code from SAS to R.
I have code from SAS which through a PROC MCMC produces a posterior bayesian distribution, allowing to specificy priors for the parameters and a binomial model on data.
If it helps the proc uses a random walk Metropolis algorithm to obtain posterior samples
I need this code in R, is there a function which does the same thing?
Thank you so much!

Hi,

I don't know SAS, but in your case I recommend paying the CRAN Bayes-view a visit. https://cran.r-project.org/web/views/Bayesian.html

Here you will find a comprehensive overview of packages available in R. Hope this gives you a start.

Cheers, JW

Hi,
I think it's a good starting point. Thanks for the link!

You might want to check out stan (specifically its R interface rstan) for Bayesian modeling. You could begin with the rstanarm package, as it has a user-friendly interface for common types of regression models and uses stan under the hood to sample from the posterior distribution.