Blog Archives

The Non-parametric Bootstrap as a Bayesian Model

April 17, 2015
By
The Non-parametric Bootstrap as a Bayesian Model

The non-parametric bootstrap was my first love. I was lost in a muddy swamp of zs, ts and ps when I first saw her. Conceptually beautiful, simple to implement, easy to understand (I thought back then, at least). And when she whispered in my ear, “I make no assumptions regarding the underlying distribution”, I was in love. This love...

Read more »

A Speed Comparison Between Flexible Linear Regression Alternatives in R

March 25, 2015
By
A Speed Comparison Between Flexible Linear Regression Alternatives in R

Everybody loves speed comparisons! Is R faster than Python? Is dplyr faster than data.table? Is STAN faster than JAGS? It has been said that speed comparisons are utterly meaningless, and in general I agree, especially when you are comparing apples and oranges which is what I’m going to do here. I’m going to compare a couple of alternatives to...

Read more »

Probable Points and Credible Intervals, Part 2: Decision Theory

January 7, 2015
By
Probable Points and Credible Intervals, Part 2: Decision Theory

“Behind every great point estimate stands a minimized loss function.” – Me, just now This is a continuation of Probable Points and Credible Intervals, a series of posts on Bayesian point and interval estimates. In Part 1 we looked at these estimates as graphical summaries, useful when it’s difficult to plot the whole posterior in good way....

Read more »

Peter Norvig’s Spell Checker in Two Lines of Base R

December 16, 2014
By
Peter Norvig’s Spell Checker in Two Lines of Base R

Peter Norvig, the director of research at Google, wrote a nice essay on How to Write a Spelling Corrector a couple of years ago. That essay explains and implements a simple but effective spelling correction function in just 21 lines of Python. Highly recommended reading! I was wondering how many lines it would take to write something similar...

Read more »

Eight Christmas Gift Ideas for the Statistically Interested

December 1, 2014
By
Eight Christmas Gift Ideas for the Statistically Interested

Christmas is soon upon us and here are some gift ideas for your statistically inclined friends (or perhaps for you to put on your own wish list). If you have other suggestions please leave a comment! :) 1. Games of probability A recently released game where probability takes the main role is Pairs, an easy going press-your-luck game that can...

Read more »

How to Summarize a 2D Posterior Using a Highest Density Ellipse

November 13, 2014
By
How to Summarize a 2D Posterior Using a Highest Density Ellipse

Making a slight digression from last month’s Probable Points and Credible Intervals here is how to summarize a 2D posterior density using a highest density ellipse. This is a straight forward extension of the highest density interval to the situation where you have a two-dimensional posterior (say, represented as a two column matrix of samples) and you want...

Read more »

Tidbits from the Books that Defined S (and R)

November 5, 2014
By
Tidbits from the Books that Defined S (and R)

Why R? Because S! R is the open source implementation (and a pun!) of S, a language for statistical computing that was developed at Bell Labs in the late 1970s. After that, the implementation of S underwent a number of major revisions documented in a series of seminal books, often just referred to by the color of their cover: The...

Read more »

Probable Points and Credible Intervals, Part 1

October 26, 2014
By
Probable Points and Credible Intervals, Part 1

After having broken the Bayesian eggs and prepared your model in your statistical kitchen the main dish is the posterior. The posterior is the posterior is the posterior, given the model and the data it contains all the information you need and anything else will be a little bit less nourishing. However, taking in the posterior in one gulp...

Read more »

Tiny Data, Approximate Bayesian Computation and the Socks of Karl Broman

October 20, 2014
By
Tiny Data, Approximate Bayesian Computation and the Socks of Karl Broman

Big data is all the rage, but sometimes you don’t have big data. Sometimes you don’t even have average size data. Sometimes you only have eleven unique socks: Karl Broman is here putting forward a very interesting problem. Interesting, not only because it involves socks, but because it involves what I would like to call Tiny...

Read more »

Bayesian First Aid: Poisson Test

September 4, 2014
By
Bayesian First Aid: Poisson Test

As the normal distribution is sort of the default choice when modeling continuous data (but not necessarily the best choice), the Poisson distribution is the default when modeling counts of events. Indeed, when all you know is the number of events during a certain period it is hard to think of any other distribution, whether you are modeling the...

Read more »