Following up on a post by Markus Gesmann, I wanted to look at logistic growth curves with a known inflection point. This is an example of functional data analysis with widespread applications, such as population dynamics and pharmacokinetics. Mages’ blog looked at the dugongs data from a textbook (Ratkowsky, 1983), which was subsequently analysed by Carlin & Gelfand (1991) and included in Vol. II of the BUGS manual as well as the Stan user guide. Markus compared point estimates from the R function nlm() with Bayesian inference using Stan. The methods were in close agreement with each other, as well as with the Gibbs sampler of Carlin & Gelfand. This made me curious to explore beyond this simple example, building towards the generalised logistic function that is a solution to the ordinary differential equation (ODE) of Richards (1959).

Previously, I’ve described my setup on Windows 7 and macOS 10.9.*x* (Mavericks). Now that I’ve got a new MacBook Air, it’s time to update these instructions for macOS 10.12.*x* (Sierra). The setup described below is quite minimal, since I have limited disk space. See the article by Bhaskar Karambelkar for an install based on homebrew that has all the bells & whistles.

Previously I’ve written my own R code to access DICOM-RT structure sets in group `3006`

of the meta-data. Shortly after I wrote that original post, Reid F. Thompson made his R package **RadOnc** available on CRAN. Unfortunately, my old code no longer works with the current version of the **oro.dicom** R package, therefore I would recommend using **RadOnc** instead. The code below is focused on importing the 3D geometry, but the R package has a lot of other features that you might find useful: for example, calculation of Dice similarity coefficient and Hausdorff distance; as well as import of dose-volume histograms (DVH).

This is a follow up to my previous post about the Swendsen-Wang (SW) algorithm, where I mentioned that SW has better convergence properties than Gibbs when the inverse temperature parameter β is large. This difference can be quantified by initialising the two algorithms at known starting points and measuring how many iterations it takes to converge. This is the second in a series of posts describing the functions and algorithms that I have implemented in the R package **bayesImageS**, which is now available on CRAN.

At the beginning of December, I presented a seminar for the PhD students of the joint Oxford-Warwick Centre for Doctoral Training (otherwise known as the OxWaSP CDT). My slides and abstract are below:

My R package was rejected the first time, due to an old bug in RcppArmadillo (details below). I also forgot to add ‘cran-comments.html’ to my .Rbuildignore after following Hadley Wickham’s otherwise excellent advice on how to develop a package for CRAN. The source package and Windows binaries are now available, with OS X soon to follow. Using R-hub was definitely helpful, since it allowed me to test my package on various flavours of Linux and versions of R before submitting it. The NOTEs didn’t come as a surprise, since running rhub::check_for_cran had already made me aware of them. Hopefully R-hub will add support for Mac OS and SPARC Solaris soon. My code has multiple compile errors in Solaris Studio 12.3, which would be painful to fix without access to a virtual machine. Continuous integration with Travis might also have been useful, but my code is hosted on Bitbucket not GitHub.

Since I’ve been invited to give a seminar at an OxWaSP mini-symposium, I decided it was finally time to get my R package **bayesImageS** in shape for submission to the CRAN repository. Recently, the R-hub builder was released as a public beta. I was keen to check this out, since it is meant to make the process of submitting packages to CRAN simpler, particularly for first time package authors such as myself.