Tuesday, May 6, 2014

Survey of Code Written to Date

Using code from this great post I have been able to construct some tables illustrating how much code I have written for this blog since 2012 (note install.packages("reshape") and install.packages("reshape") might be necessary).

The top left plot shows number of files with over 200 files written with a .do extension for Stata, over 100 with .r, and a small number in .jl for Julia.  The second graph shows file length by date.  One can see the general increase in R posts in both frequency and length.  The bottom left graph shows a density graph of files by file length.  We can see that the highest density of files peaking around 100 lines with long tales with some files being as long as 400+ lines of code.  The final graph shows cumulative file length over time. 

It is easy to see on this graph how coding and blogging comes in fits and starts.  So far this graph seems to indicate that I have coded more than 20 thousand lines of code in Stata and over 10 thousand in R.  Julia is just a speck on this graph.  I hope to post more in Julia in the future.


  1. I wish you would do more simulations again.

    1. Thanks, I got married so ended up being a little busy this last month.