Blog posts

I've been using blogger to write my blog posts for a while now. I started a blog together with my colleague Sandro when we were working at the Theoretical Biology group at Utrecht University. Our office was Z533, which is why we called our blog TBZ533. I've listed some more popular or interesting posts from this blog below.

2023

Contributing code to Stan

less than 1 minute read

Published:

I wrote a blog post about how to contribute code to Stan. This was quite a long process for a noob like me, resulting in a long blog post. In this post, I will guide you through the process of implementing new native distributions in Stan, writing documentation and tests, modifying the Stan compiler, and creating pull requests on GitHub.

2020

Generalized Profiling with Stan

less than 1 minute read

Published:

This post is about implementing the generalized profiling method in Stan. Fitting ODE models to timeseries data can be hard, especially if the data shows signs of process noise that cannot be simply absorbed into the measurement noise. A good example is periodic dynamics, in which the phase drifts with time. The deterministic prediction will in this case get out of phase with the stochastic data.

2018

Bayesian Multi-dimensional scaling (MDS)

less than 1 minute read

Published:

Antigenic cartography maps viruses and sera to a two-dimensional space to visualize their relation and the pace of antigenic drift. As antigens and antibodies are typically very high dimensional objects, special methods to embed them into lower dimensional spaces are required. MDS is one such method. In this post, I show how to implement a Bayesian version of MDS and apply this to influenza data.

2017

How to calculate WBIC with Stan

less than 1 minute read

Published:

In Bayesian statistics, model comparison ideally is based on Bayes factors. However, these are not always easy to compute. For this reason, approximate measures have been developed. One of these measures is the WBIC, which has is similar to the BIC, but is not merely based on a point estimate and is valid for a larger class of models. In this post, I show how to compute WBIC with a Stan model.