Getting started with Bayesian in R

Stan logo

There really is no excuse any more: getting started with Bayesian regression analysis in R is really simple.

Step 1: install rstanarm from CRAN

Step 2: replace lm() with stan_glm() in your code

Sure, you’ll probably want to learn about priors, and invest a little in understanding diagnostics such as those provided by ShinyStan. But rstanarm is really designed to work well out of the box (i.e. with your existing code).

What I really appreciate is that it has useful warnings and error messages, and extensive documentation. Sometimes the documentation shows that quantitative analysis has something to do with mathematics, but even those who skip the Greek letters and formulae will get enough guidance. You’ll get nudges to use your own priors rather than rely on the default priors, but in my experience for most simple applications the default priors work reasonably well. You’ll also get suggestions right on your screen what you can do when there are say divergent transitions.

Once you can handle rstanarm, you’ll find it easy to upgrade to brms, where you can still use your trusted syntax for regression models in base R.


I had fun this morning when checking the results of the routing plagiarism check. There was one paper flagged as suspicious because it used quotes from published articles without quotation marks. It turns out, the student was guilty of using French-style quotation marks for English quotes — clearly inappropriate… not!

Could not connect to SciFlow

In the past few days, I could not log into SciFlow:

Something went wrong.
No session found

Please try again. If the problem persist, please reach out to

Well, I did contact the excellent customer service, and it turns out that they tweaked their cookie settings. Which simply means: clear out your SciFlow cookies, and keep writing!

Read/write access for Samba/cfis drive remotely using GNU/Linux

I’ve had some issues with accessing a remote network drive: I didn’t have the permission to write on the network drive, even though I should. Changing the permissions manually would have worked, but that seemed like the wrong approach. I didn’t log into this particular drive for a while, so I figured my mount options were probably incorrect. Turns out (as usual) that the solution was to set the uid option:

mkdir -p ~/mnt/remote_username

sudo mount -t cifs -o user=remote_username,,uid=local_username //home/remote_username$ ~/mnt/remote_username