What ?

littler provides the r program, a simplified command-line interface for GNU R. This allows direct execution of commands, use in piping where the output of one program supplies the input of the next, as well as adding the ability for writing hash-bang scripts, i.e. creating executable files starting with, say, #!/usr/bin/r.

Both the examples page and the examples vignette provide several illustrations.

Why ?

GNU R, a language and environment for statistical computing and graphics, provides a wonderful system for ‘programming with data’ as well as interactive exploratory analysis, often involving graphs.

Sometimes, however, simple scripts are desired. While R can be used in batch mode, and while so-called here documents can be crafted, a long-standing need for a scripting front-end has often been expressed by the R community.

littler (pronounced little R and written r) has been filling this need since 2006 (and since before Rscript appeared).

A few examples are provided in a companion webpage with examples as well as in the source directories inst/examples/ and inst/script-tests/.

Several moderately visible projects trust littler in an industrial-strength setting. CRANberries has been using it since July 2007 to provide detailed and immediate updates about new and updated packages at CRAN via RSS feeds, HTML pages and for the last few years also tweets. The more recent CRAN Policy Watch is similarly driven by a cronjob launching r to check for changes in published CRAN Policy page (which are rarely announced officially). Our Rocker project building Docker containers for R (including the official r-base one) rely on r for package installation.

Where ?

Since release 0.3.0, littler is a CRAN package and can be installed via


Older versions relied on configure; make; make install and tarballs can still be downloaded from the local archive here or accessed via its GitHub repository in source or release form.

It can also be obtained from Debian mirrors via a simple

apt-get install r-cran-littler

provided apt is pointed to the testing or unstable distributions. It is also available on the [Ubuntu backports of R at CRAN])(https://cran.rstudio.com/bin/linux/ubuntu/). (Note that up to release 0.2.3, the binary packages was called littler rather than r-cran-littler.)

littler is known to build and run on Linux and OS X. On OS X, you may want to link or copy it to lr as that particular OS thinks R and r are the same. (Hint: They’re not.)

What else ?

A few more questions are addressed in the README file which also contains a brief FAQ section.

Also see the examples page to see several simple r invocations.

When ?

Jeff Horner created littler around 2006 having created the awesome rApache embedding of GNU R in the Apache browser. Dirk Eddelbuettel joined early on, helped with the build system and some extensions and has been maintaining it ever since. The release of littler preceded the first version Rscript by several months.

Littler reached its current form pretty early on, and has been stable since the early release. Several small refinements were added over the years. Littler also forms the basis of RInside which embeds GNU R inside a comvenient C++ class abstraction.

The previous repository was at Google Code which we left in 2013 for the current GitHub repo.

Who ?

Copyright (C) 2006 - 2015 Jeffrey Horner and Dirk Eddelbuettel

Comments are welcome, as are are suggestions, bug fixes, or patches.

Initially created: Sun Sep 25 14:16:18 CDT 2006
Last modified: Sat May 30 08:26:28 CDT 2020