lumberjack 1.2.0 is on CRAN and paper accepted by JSS

lumberjack is a package that allows you to track (log) changes in data while an R script is running. This allows you to detect exactly which code had what effect on your data.

The only thing you have to do is

  1. add one line of code at the top of your script, for example:
, expression_logger$new(m = mean(salary, na.rm=TRUE))

to follow the mean of variable salary in mydata as mydata gets processed by one line of code at the time.

  1. Run your script with

and your script will run as usual, except that the mean salary is tracked across the run, and (in this case) automatically written to a file. The package is extensible so you can use one of the built-in loggers, or write your own.

If you want to know more, I highly recommend reading through my short paper on lumberjack that was recently accepted by the Journal of Statistical Software.

New release

Version 1.2.0 was accepted by CRAN on 8 may 2020. There are a few new features and fixes. Some of them suggested by one of the JSS

  • The most important change is that loggers now not only know what expression is running, but also from which file it originated, and from which line. This means that loggers can give even more informative information on when a script did what to data.
  • The JSS paper is now included as a vignette.


Here's a picture of a man, trying hard to look like a lumberjack while staring into the void.

I'm a lumberjack and I'm ok

This entry was posted in programming, R and tagged , , , , , . Bookmark the permalink.

Leave a Reply

Your email address will not be published. Required fields are marked *

Time limit is exhausted. Please reload CAPTCHA.