R has some extremely useful utilities for profiling, such as system.time(), Rprof(), the often overlooked tracemem(), and the rbenchmark package. But if you want more than just simple timings of code execution, you will mostly have to look elsewhere. One of the best sources for profiling data is hardware performance counters, available in most modern hardware. This data can be invaluable to understanding Read more >>
So you've probably heard of King James Programming; if not, you should check it out because it's great. A quick summary is that someone took the King James Bible and Sussman's Structure and Interpretation of Computer Programs (SICP) and used an n-gram babbler to generate new sentences that combine the texts in amusing ways. The generator itself is a Markov Chain, which has a very special place in my Read more >>
This is not nearly as interesting as it might first sound, but every function in R contains R code; this is true of core R code as well as extension packages. Sometimes the R code is just a very shallow wrapper around some compiled code, such as in sum() and is.null(). Other times, as in lm.fit(), there is a vast expanse of R code. It's easy enough to print this source code; simply type in the Read more >>
I have a lot of projects that will take ages to finish (some are in such poor shape that I tuck them away in private repositories, so no one can see my shame).  So sometimes it's nice to just take a weekend and crank out something start to finish, even if it's dumb and no one cares about it and fewer people want it.  Which brings us to the matter at hand.  There's a relatively famous XKCD comic Read more >>
For some reason, a relatively uninteresting observation of Ramanujan has become a bit of an internet celebrity among factoids lately.  Someone who's out to generate link bait makes a post stating that $latex 1+2+3+\dots = \frac{-1}{12}$ Now look.  I appreciate trolling as much as the next jerk, but people who really ought to know better are getting tricked by this.  In the usual sense of convergence, Read more >>
Naming Rules in R How are objects allowed to be named in R? As it turns out, this is a very different question from how should objects be named. This isn't about style conventions, camelCase, dots.verus_underscores, or anything like that; this is about what is strictly possible. I do a lot of outreach to HPC people who are starting to get an interest in R, often because their users are starting Read more >>
Sometimes intentionally writing bad code can be a lot of fun. Now here, when I say "bad", I mean something that's functional but completely incoherent to anything but the machine. There are even competitions for this kind of thing, but I only consider myself a dabbler in this dark art. Thankfully, it's often pretty easy to make obtuse code in R. Given that I have a weird admiration for bad code Read more >>
I've been too quiet around here for too long. I plan to rectify that soon.  As for why I've been absent for so long, the very short answer is that I lost the energy.  I'm working on a lot of really new and exciting software projects (~6 of them side projects I work on in my free time, mostly by myself).  Combine this with an aggressive work schedule, lots of traveling for the summer conference season, Read more >>