Yesterday I wrote some R code to simulate the quincunx, and I wrote an R function quincunx() in the animation package. Here is a video:
quincunx()