littler v0.3.5

0

Monthly downloads

0th

Percentile

R at the Command-Line via 'r'

A scripting and command-line front-end is provided by 'r' (aka 'littler') as a lightweight binary wrapper around the GNU R language and environment for statistical computing and graphics. While R can be used in batch mode, the r binary adds full support for both 'shebang'-style scripting (i.e. using a hash-mark-exclamation-path expression as the first line in scripts) as well as command-line use in standard Unix pipelines. In other words, r provides the R language without the environment.

Readme

littler Build Status License CRAN Downloads

A scripting and command-line front-end for GNU R permitting use of R in command-line contexts.

So What Is It For?

#!/usr/bin/env r              ## for use in scripts

other input | r               ## for use in pipes

r somefile.R                  ## for running files

r -e 'expr'                   ## for evaluating expressions

r --help                      ## to show a quick synopsis

Examples?

Plenty. See the examples vignette for a full set of introductory examples. Also see the examples/ directory for a full 28 example scripts, as well as maybe the older tests directory both of which are installed with the package.

Some scripts I uses daily or near daily (in alphabetical order):

build.r                                ## builds from the current directory
c4c.r                                  ## submits current directory to winbuilder
compAttr.r                             ## run compileAttributes() for a Rcpp package
dratInstert.r 1.2-3.tar.gz -r /srv     ## inserts package into drat repo
install.r abc def                      ## installs packages abc and def
install.r abc_1.2-3.tar.gz             ## installs given tarball
install2.r -l /tmp/lib abc def         ## installs abc and def into /tmp/lib
rcc.r abc_1.2-3.tar.gz                 ## run's R CMD check via Gabor's rcmdcheck
render.r foo.Rmd                       ## calls rmarkdown::render()
roxy.r                                 ## run roxyenize() for a package (only Rd creation)
update.r                               ## updates any currently installed packages

Installation

Version 0.3.0 or later

The package resides on the CRAN network and can be installed via

install.packages("littler")

Previous Versions up to 0.2.3

In general, simply running the script bootstrap will configure and build the executable. Running make install (possibly as sudo make install) will install the resulting binary.

On Linux systems, ensure you have the autotools-dev package (or its equivalent on non-Debian/Ubuntu systems). On OS X, you may need to run brew install automake autoconf to get all the tools.

Alternate Naming

On some operating systems such as OS X, r is not different from R. As this risk confusing the main binary R for the R system with our smaller scripting frontend r, we suggest to consider running configure --program-prefix="l" which this leads to installation of a binary lr instead of r.

Alternate R Version

As littler uses autoconf its AC_PATH_PROG() macro to find R, one can simply adjust the PATH when calling configure (or, rather, bootstrap) to have another version of R used. For example, on a server with R-devel in this location, the following builds littler using this R-devel version: PATH="/usr/local/lib/R-devel/bin/:$PATH" ./bootstrap.

More Information

For more information about littler, please see

(but note that the latter now overlaps with the example vignette).

Authors

Jeff Horner (2006 to 2008) and Dirk Eddelbuettel (since 2006)

License

GPL (>= 2)

Functions in littler

Name Description
littler Command-line and scripting front-end for R
r Return Path to r Binary
No Results!

Vignettes of littler

Name
littler-examples.Rmd
No Results!

Last month downloads

Details

Type Package
Date 2018-10-04
URL http://dirk.eddelbuettel.com/code/littler.html
BugReports https://github.com/eddelbuettel/littler/issues
License GPL (>= 2)
OS_type unix
SystemRequirements libR
VignetteBuilder knitr
RoxygenNote 5.0.1
NeedsCompilation yes
Packaged 2018-10-04 12:39:20.117291 UTC; edd
Repository CRAN
Date/Publication 2018-10-04 13:00:03 UTC

Include our badge in your README

[![Rdoc](http://www.rdocumentation.org/badges/version/littler)](http://www.rdocumentation.org/packages/littler)