[R] static analysis tools for R code?

Prof Brian Ripley ripley at stats.ox.ac.uk
Mon Apr 11 16:36:36 CEST 2005


Look at Luke Tierney's codetools package.

https://stat.ethz.ch/pipermail/r-devel/2003-July/027103.html

It is useful, and has been run over R itself several times.

On Mon, 11 Apr 2005, Vivek Rao wrote:

> An R script will terminate when one tries to use an
> undefined variable, with a message such as
>
> Error in print(x) : Object "x" not found
>
> This run-time error might occur after the script has
> already been running for some time. In some cases it
> would be nice to get such warnings before the script
> is run, just as a syntax error caused by a missing
> parenthesis is caught.
>
> Are there any "static analysis" tools for R? Such a
> tool would not have to be perfect to be useful.
> Besides using undefined variables, defining variables
> that are never used is something I'd like to be warned
> about.

-- 
Brian D. Ripley,                  ripley at stats.ox.ac.uk
Professor of Applied Statistics,  http://www.stats.ox.ac.uk/~ripley/
University of Oxford,             Tel:  +44 1865 272861 (self)
1 South Parks Road,                     +44 1865 272866 (PA)
Oxford OX1 3TG, UK                Fax:  +44 1865 272595




More information about the R-help mailing list