[Rcpp-commits] r4353 - in pkg/RcppGSL: . vignettes vignettes/RcppGSL vignettes/unitTests
noreply at r-forge.r-project.org
noreply at r-forge.r-project.org
Thu Jun 20 00:42:17 CEST 2013
Author: romain
Date: 2013-06-20 00:42:16 +0200 (Thu, 20 Jun 2013)
New Revision: 4353
Added:
pkg/RcppGSL/vignettes/Makefile
pkg/RcppGSL/vignettes/RcppGSL-unitTests.Rnw
pkg/RcppGSL/vignettes/RcppGSL/
pkg/RcppGSL/vignettes/RcppGSL/RcppGSL-fake.Rnw
pkg/RcppGSL/vignettes/RcppGSL/RcppGSL-intro.Rnw
pkg/RcppGSL/vignettes/unitTests-results/
pkg/RcppGSL/vignettes/unitTests/
pkg/RcppGSL/vignettes/unitTests/RcppGSL-unitTests.R
Modified:
pkg/RcppGSL/DESCRIPTION
Log:
revert back to Makefile
Modified: pkg/RcppGSL/DESCRIPTION
===================================================================
--- pkg/RcppGSL/DESCRIPTION 2013-06-19 22:13:52 UTC (rev 4352)
+++ pkg/RcppGSL/DESCRIPTION 2013-06-19 22:42:16 UTC (rev 4353)
@@ -31,4 +31,3 @@
Suggests: RUnit, inline
LinkingTo: Rcpp
SystemRequirements: GNU GSL
-VignetteBuilder: highlight
Added: pkg/RcppGSL/vignettes/Makefile
===================================================================
--- pkg/RcppGSL/vignettes/Makefile (rev 0)
+++ pkg/RcppGSL/vignettes/Makefile 2013-06-19 22:42:16 UTC (rev 4353)
@@ -0,0 +1,50 @@
+
+## There is an old bug in texidvi that makes it not swallow the ~
+## marker used to denote whitespace. This is actually due to fixing
+## another bug whereby you could not run texidvi on directory names
+## containing a tilde (as we happen to do for Debian builds of R
+## alpha/beta/rc releases). The 'tilde' bug will go away as it
+## reportedly has been squashed upstream but I am still bitten by it
+## on Ubuntu so for now Dirk will insist on pdflatex and this helps.
+whoami=$(shell whoami)
+
+all: RcppGSL-unitTests.pdf RcppGSL-intro.pdf
+
+clean:
+ rm -f RcppGSL*.log RcppGSL*.aux RcppGSL*.out RcppGSL*.tex *.blg *.bbl *~
+ rm -rf auto/
+
+pdfclean:
+ rm -f RcppGSL-unitTests.pdf RcppGSL-intro.pdf
+
+setvars:
+ifeq (${R_HOME},)
+R_HOME= $(shell R RHOME)
+endif
+RPROG= $(R_HOME)/bin/R
+RSCRIPT=$(R_HOME)/bin/Rscript
+
+RcppGSL-unitTests.pdf:
+ rm -fr unitTests-results/*
+ $(RSCRIPT) --vanilla unitTests/RcppGSL-unitTests.R
+ $(RPROG) CMD Sweave RcppGSL-unitTests.Rnw
+ $(RSCRIPT) --vanilla -e "tools::texi2dvi( 'RcppGSL-unitTests.tex', pdf = TRUE, clean = TRUE )"
+ rm -fr RcppGSL-unitTests.tex
+
+RcppGSL-intro.pdf: RcppGSL/RcppGSL-intro.Rnw
+ cp -f RcppGSL/RcppGSL-intro.Rnw .
+ $(RSCRIPT) --vanilla -e "require(highlight); driver <- HighlightWeaveLatex(boxes = TRUE); Sweave( 'RcppGSL-intro.Rnw', driver = driver ); "
+ifneq (,$(findstring edd,$(whoami)))
+ pdflatex RcppGSL-intro
+else
+ $(RSCRIPT) -e "tools::texi2dvi( 'RcppGSL-intro.tex', pdf = TRUE, clean = FALSE )"
+endif
+ bibtex RcppGSL-intro
+ifneq (,$(findstring edd,$(whoami)))
+ pdflatex RcppGSL-intro
+ pdflatex RcppGSL-intro
+else
+ $(RSCRIPT) -e "tools::texi2dvi( 'RcppGSL-intro.tex', pdf = TRUE, clean = TRUE )"
+endif
+ rm -fr RcppGSL-intro.tex RcppGSL-intro.bbl RcppGSL-intro.blg RcppGSL-intro.aux RcppGSL-intro.out RcppGSL-intro.log
+ cp RcppGSL/RcppGSL-fake.Rnw RcppGSL-intro.Rnw
Added: pkg/RcppGSL/vignettes/RcppGSL/RcppGSL-fake.Rnw
===================================================================
--- pkg/RcppGSL/vignettes/RcppGSL/RcppGSL-fake.Rnw (rev 0)
+++ pkg/RcppGSL/vignettes/RcppGSL/RcppGSL-fake.Rnw 2013-06-19 22:42:16 UTC (rev 4353)
@@ -0,0 +1,11 @@
+\documentclass[10pt]{article}
+%\VignetteIndexEntry{RcppGSL}
+
+\usepackage{url}
+\usepackage[colorlinks]{hyperref}
+\setlength{\oddsidemargin}{0pt}
+\setlength{\textwidth}{17cm} % uh-oh, I use letter :)
+
+\begin{document}
+\end{document}
+
Added: pkg/RcppGSL/vignettes/RcppGSL/RcppGSL-intro.Rnw
===================================================================
--- pkg/RcppGSL/vignettes/RcppGSL/RcppGSL-intro.Rnw (rev 0)
+++ pkg/RcppGSL/vignettes/RcppGSL/RcppGSL-intro.Rnw 2013-06-19 22:42:16 UTC (rev 4353)
@@ -0,0 +1,1126 @@
+\documentclass[10pt]{article}
+%\VignetteIndexEntry{RcppGSL}
+%\VignetteKeywords{R,GSL,Rcpp,data transfer}
+%\VignettePackage{RcppGSL}
+
+\usepackage{url,color}
+\usepackage[authoryear,round,longnamesfirst]{natbib}
+\usepackage[colorlinks]{hyperref}
+\definecolor{link}{rgb}{0,0,0.3} %% next few lines courtesy of RJournal.sty
+\hypersetup{
+ colorlinks,%
+ citecolor=link,%
+ filecolor=link,%
+ linkcolor=link,%
+ urlcolor=link
+}
+\usepackage{vmargin}
+\setmargrb{0.75in}{0.75in}{0.75in}{0.75in}
+\usepackage{booktabs} % fancier \hrule
+
+\newcommand{\proglang}[1]{\textsf{#1}}
+\newcommand{\pkg}[1]{{\fontseries{b}\selectfont #1}}
+
+\RequirePackage{ae,mathpple} % ae as a default font pkg works with Sweave
+\RequirePackage[T1]{fontenc}
+
+<<setup,echo=FALSE,print=FALSE>>=
+require(inline)
+library(RcppGSL)
+options("width"=65)
+rcppgsl.version <- packageDescription( "RcppGSL" )$Version
+prettyDate <- format(Sys.Date(), "%B %e, %Y")
+@
+% closing $ needed here
+
+\author{Dirk Eddelbuettel \and Romain Fran\c{c}ois}
+\title{\pkg{RcppGSL}: Easier \pkg{GSL} use from \proglang{R} via \pkg{Rcpp}}
+\date{Version \Sexpr{rcppgsl.version} as of \Sexpr{prettyDate}}
+
+\begin{document}
+\maketitle
+
+\abstract{
+ \shortcites{GSL} %% so that we get Galassi et al instead of all names
+ \noindent
+ The GNU Scientific Library, or \pkg{GSL}, is a collection of numerical
+ routines for scientific computing \citep{GSL}. It is particularly useful for
+ \proglang{C} and \proglang{C++} programs as it provides a standard
+ \proglang{C} interface to a wide range of mathematical routines such as
+ special functions, permutations, combinations, fast fourier transforms,
+ eigensystems, random numbers, quadrature, random distributions,
+ quasi-random sequences, Monte Carlo integration, N-tuples, differential
+ equations, simulated annealing, numerical differentiation, interpolation,
+ series acceleration, Chebyshev approximations, root-finding, discrete
+ Hankel transforms physical constants, basis splines and wavelets. There
+ are over 1000 functions in total with an extensive test suite.
+
+ The \pkg{RcppGSL} package provides an easy-to-use interface between
+ \pkg{GSL} data structures and \proglang{R} using concepts from \pkg{Rcpp}
+ \citep{JSS:Rcpp,CRAN:Rcpp} which is itself a package that eases the interfaces
+ between \proglang{R} and C++.
+}
+
+\section{Introduction}
+
+The GNU Scientific Library, or \pkg{GSL}, is a collection of numerical
+routines for scientific computing \citep{GSL}. It is a rigourously developed
+and tested library providing support for a wide range of scientific or
+numerical tasks. Among the topics covered in the GSL are
+%% from the GSL manual
+complex numbers, roots of polynomials,
+special functions, vector and matrix data structures,
+permutations, combinations, sorting, BLAS support,
+linear algebra, fast fourier transforms, eigensystems,
+random numbers, quadrature, random distributions, quasi-random sequences,
+Monte Carlo integration, N-tuples,
+differential equations, simulated annealing,
+numerical differentiation, interpolation,
+series acceleration, Chebyshev approximations,
+root-finding, discrete Hankel transforms
+least-squares fitting, minimization,
+physical constants, basis splines and wavelets.
+
+Support for \proglang{C} programming with the GSL is readily available: the GSL itself is written in \proglang{C}
+and provides a \proglang{C}-language Application Programming Interface
+(API). Access from \proglang{C++} is therefore possible, albeit not at the
+abstraction level that can be offered by dedicated \proglang{C++}
+implementations.\footnote{Several \proglang{C++} wrappers for the GSL have
+ been written over the years yet none reached a state of completion
+ comparable to the GSL itself. Three such wrapping library are
+ \url{http://cholm.home.cern.ch/cholm/misc/gslmm/},
+ \url{http://gslwrap.sourceforge.net/} and
+ \url{http://code.google.com/p/gslcpp/}.}
+
+The GSL is somewhat unique among numerical libraries. Its combination of
+broad coverage of scientific topics, serious implementation effort and the
+use of a FLOSS license have lead to a fairly wide usage of the library. As a
+concrete example, we can consider the the CRAN repository network for the
+\proglang{R} language and environment \citep{R:Main}. CRAN contains over a
+dozen packages interfacing the GSL: \pkg{copula}, \pkg{dynamo}, \pkg{gsl},
+\pkg{gstat}, \pkg{magnets}, \pkg{mvabund}, \pkg{QRMlib}, \pkg{RBrownie},
+\pkg{RDieHarder}, \pkg{RHmm}, \pkg{segclust}, \pkg{surveillance}, and
+\pkg{topicmodels}. This is a clear indication that the GSL is popular among
+programmers using either the \proglang{C} or \proglang{C++} language for
+solving problems applied science.
+
+At the same time, the \pkg{Rcpp} package \citep{JSS:Rcpp,CRAN:Rcpp} offers a
+higher-level abstraction between \proglang{R} and underlying \proglang{C++}
+(or \proglang{C}) code. \pkg{Rcpp} permits \proglang{R} objects like
+vectors, matrices, lists, functions, environments, $\ldots$, to be
+manipulated directly at the \proglang{C++} level, alleviates the needs for
+complicated and error-prone parameter passing and memory allocation. It also
+permits compact vectorised expressions similar to what can be written in
+\proglang{R} directly at the \proglang{C++} level.
+
+The \pkg{RcppGSL} package discussed here aims the help close the gap. It
+tries to offer access to GSL functions, in particular via the vector and
+matrix data structures used throughout the GSL, while staying closer to the
+`whole object model' familar to the \proglang{R} programmer.
+
+The rest of paper is organised as follows. The next section shows a
+motivating example of a fast linear model fit routine using \pkg{GSL} functions.
+The following section discusses support for \pkg{GSL} vector types, which is
+followed by a section on matrices.
+
+\section{Motivation: FastLm}
+
+Fitting linear models is a key building block of analysing data and
+modeling. \proglang{R} has a very complete and feature-rich function in
+\texttt{lm()} which can provide a model fit as we a number of diagnostic
+measure, either directly or via the corresponding \texttt{summary()} method
+for linear model fits. The \texttt{lm.fit()} function also provides a faster
+alternative (which is however recommend only for for advanced users) which
+provides estimates only and fewer statistics for inference. This sometimes
+leads users request a routine which is both fast and featureful enough. The
+\texttt{fastLm} routine shown here provides such an implementation. It uses
+the \pkg{GSL} for the least-squares fitting functions and therefore provides a nice
+example for \pkg{GSL} integration with \proglang{R}.
+
+% < < fastLm,lang=cpp,size=small > > =
+% #include <RcppGSL.h>
+% #include <gsl/gsl_multifit.h>
+% #include <cmath>
+
+% extern "C" SEXP fastLm(SEXP ys, SEXP Xs) {
+
+% try {
+% RcppGSL::vector<double> y = ys; // create gsl data structures from SEXP
+% RcppGSL::matrix<double> X = Xs;
+
+% int n = X.nrow(), k = X.ncol();
+% double chisq;
+
+% RcppGSL::vector<double> coef(k); // to hold the coefficient vector
+% RcppGSL::matrix<double> cov(k,k); // and the covariance matrix
+
+% // the actual fit requires working memory we allocate and free
+% gsl_multifit_linear_workspace *work = gsl_multifit_linear_alloc (n, k);
+% gsl_multifit_linear (X, y, coef, cov, &chisq, work);
+% gsl_multifit_linear_free (work);
+
+% // extract the diagonal as a vector view
+% gsl_vector_view diag = gsl_matrix_diagonal(cov) ;
+
+% // currently there is not a more direct interface in Rcpp::NumericVector
+% // that takes advantage of wrap, so we have to do it in two steps
+% Rcpp::NumericVector std_err ; std_err = diag;
+% std::transform( std_err.begin(), std_err.end(), std_err.begin(), sqrt);
+
+% Rcpp::List res = Rcpp::List::create(Rcpp::Named("coefficients") = coef,
+% Rcpp::Named("stderr") = std_err,
+% Rcpp::Named("df") = n - k);
+
+% // free all the GSL vectors and matrices -- as these are really C data structures
+% // we cannot take advantage of automatic memory management
+% coef.free(); cov.free(); y.free(); X.free();
+
+% return res; // return the result list to R
+
+% } catch( std::exception &ex ) {
+% forward_exception_to_r( ex );
+% } catch(...) {
+% ::Rf_error( "c++ exception (unknown reason)" );
+% }
+% return R_NilValue; // -Wall
+% }
+% @
+
+\begin{small}
+\begin{Hchunk}
+\noindent
+\ttfamily
+\hlstd{}\hldir{\#include\ \usebox{\hlsmallboxlessthan}RcppGSL.h\usebox{\hlsmallboxgreaterthan}}\hspace*{\fill}\\
+\hlstd{}\hldir{\#include\ \usebox{\hlsmallboxlessthan}gsl/gsl\textunderscore multifit.h\usebox{\hlsmallboxgreaterthan}}\hspace*{\fill}\\
+\hlstd{}\hldir{\#include\ \usebox{\hlsmallboxlessthan}cmath\usebox{\hlsmallboxgreaterthan}}\hspace*{\fill}\\
+\hlstd{}\hspace*{\fill}\\
+\hlkwc{extern\ }\hlstd{}\hlstr{"C"}\hlstd{\ SEXP\ }\hlkwd{fastLm}\hlstd{}\hlsym{(}\hlstd{SEXP\ ys}\hlsym{,\ }\hlstd{SEXP\ Xs}\hlsym{)\ \usebox{\hlsmallboxopenbrace}}\hspace*{\fill}\\
+\hlstd{\hspace*{\fill}\\
+}\hlstd{\ \ }\hlstd{}\hlkwa{try\ }\hlstd{}\hlsym{\usebox{\hlsmallboxopenbrace}}\hspace*{\fill}\\
+\hlstd{}\hlstd{\ \ \ \ \ \ \ \ }\hlstd{RcppGSL}\hlsym{::}\hlstd{vector}\hlsym{\usebox{\hlsmallboxlessthan}}\hlstd{}\hlkwb{double}\hlstd{}\hlsym{\usebox{\hlsmallboxgreaterthan}\ }\hlstd{y\ }\hlsym{=\ }\hlstd{ys}\hlsym{;}\hlstd{\ \ \ \ \ }\hlsym{}\hlstd{}\hlslc{//\ create\ gsl\ data\ structures\ from\ SEXP}\hspace*{\fill}\\
+\hlstd{}\hlstd{\ \ \ \ \ \ \ \ }\hlstd{RcppGSL}\hlsym{::}\hlstd{matrix}\hlsym{\usebox{\hlsmallboxlessthan}}\hlstd{}\hlkwb{double}\hlstd{}\hlsym{\usebox{\hlsmallboxgreaterthan}\ }\hlstd{X\ }\hlsym{=\ }\hlstd{Xs}\hlsym{;}\hspace*{\fill}\\
+\hlstd{\hspace*{\fill}\\
+}\hlstd{\ \ \ \ \ \ \ \ }\hlstd{}\hlkwb{int\ }\hlstd{n\ }\hlsym{=\ }\hlstd{X}\hlsym{.}\hlstd{}\hlkwd{nrow}\hlstd{}\hlsym{(),\ }\hlstd{k\ }\hlsym{=\ }\hlstd{X}\hlsym{.}\hlstd{}\hlkwd{ncol}\hlstd{}\hlsym{();}\hspace*{\fill}\\
+\hlstd{}\hlstd{\ \ \ \ \ \ \ \ }\hlstd{}\hlkwb{double\ }\hlstd{chisq}\hlsym{;}\hspace*{\fill}\\
+\hlstd{\hspace*{\fill}\\
+}\hlstd{\ \ \ \ \ \ \ \ }\hlstd{RcppGSL}\hlsym{::}\hlstd{vector}\hlsym{\usebox{\hlsmallboxlessthan}}\hlstd{}\hlkwb{double}\hlstd{}\hlsym{\usebox{\hlsmallboxgreaterthan}\ }\hlstd{}\hlkwd{coef}\hlstd{}\hlsym{(}\hlstd{k}\hlsym{);}\hlstd{\ \ \ \ }\hlsym{}\hlstd{}\hlslc{//\ to\ hold\ the\ coefficient\ vector}\hspace*{\fill}\\
+\hlstd{}\hlstd{\ \ \ \ \ \ \ \ }\hlstd{RcppGSL}\hlsym{::}\hlstd{matrix}\hlsym{\usebox{\hlsmallboxlessthan}}\hlstd{}\hlkwb{double}\hlstd{}\hlsym{\usebox{\hlsmallboxgreaterthan}\ }\hlstd{}\hlkwd{cov}\hlstd{}\hlsym{(}\hlstd{k}\hlsym{,}\hlstd{k}\hlsym{);}\hlstd{\ \ \ }\hlsym{}\hlstd{}\hlslc{//\ and\ the\ covariance\ matrix}\hspace*{\fill}\\
+\hlstd{\hspace*{\fill}\\
+}\hlstd{\ \ \ \ \ \ \ \ }\hlstd{}\hlslc{//\ the\ actual\ fit\ requires\ working\ memory\ we\ allocate\ and\ free}\hspace*{\fill}\\
+\hlstd{}\hlstd{\ \ \ \ \ \ \ \ }\hlstd{gsl\textunderscore multifit\textunderscore linear\textunderscore workspace\ }\hlsym{{*}}\hlstd{work\ }\hlsym{=\ }\hlstd{}\hlkwd{gsl\textunderscore multifit\textunderscore linear\textunderscore alloc\ }\hlstd{}\hlsym{(}\hlstd{n}\hlsym{,\ }\hlstd{k}\hlsym{);}\hspace*{\fill}\\
+\hlstd{}\hlstd{\ \ \ \ \ \ \ \ }\hlstd{}\hlkwd{gsl\textunderscore multifit\textunderscore linear\ }\hlstd{}\hlsym{(}\hlstd{X}\hlsym{,\ }\hlstd{y}\hlsym{,\ }\hlstd{coef}\hlsym{,\ }\hlstd{cov}\hlsym{,\ \&}\hlstd{chisq}\hlsym{,\ }\hlstd{work}\hlsym{);}\hspace*{\fill}\\
+\hlstd{}\hlstd{\ \ \ \ \ \ \ \ }\hlstd{}\hlkwd{gsl\textunderscore multifit\textunderscore linear\textunderscore free\ }\hlstd{}\hlsym{(}\hlstd{work}\hlsym{);}\hspace*{\fill}\\
+\hlstd{\hspace*{\fill}\\
+}\hlstd{\ \ \ \ \ \ \ \ }\hlstd{}\hlslc{//\ extract\ the\ diagonal\ as\ a\ vector\ view}\hspace*{\fill}\\
+\hlstd{}\hlstd{\ \ \ \ \ \ \ \ }\hlstd{gsl\textunderscore vector\textunderscore view\ diag\ }\hlsym{=\ }\hlstd{}\hlkwd{gsl\textunderscore matrix\textunderscore diagonal}\hlstd{}\hlsym{(}\hlstd{cov}\hlsym{)\ ;}\hspace*{\fill}\\
+\hlstd{\hspace*{\fill}\\
+}\hlstd{\ \ \ \ \ \ \ \ }\hlstd{}\hlslc{//\ currently\ there\ is\ not\ a\ more\ direct\ interface\ in\ Rcpp::NumericVector}\hspace*{\fill}\\
+\hlstd{}\hlstd{\ \ \ \ \ \ \ \ }\hlstd{}\hlslc{//\ that\ takes\ advantage\ of\ wrap,\ so\ we\ have\ to\ do\ it\ in\ two\ steps}\hspace*{\fill}\\
+\hlstd{}\hlstd{\ \ \ \ \ \ \ \ }\hlstd{Rcpp}\hlsym{::}\hlstd{NumericVector\ std\textunderscore err\ }\hlsym{;\ }\hlstd{std\textunderscore err\ }\hlsym{=\ }\hlstd{diag}\hlsym{;}\hspace*{\fill}\\
+\hlstd{}\hlstd{\ \ \ \ \ \ \ \ }\hlstd{std}\hlsym{::}\hlstd{}\hlkwd{transform}\hlstd{}\hlsym{(\ }\hlstd{std\textunderscore err}\hlsym{.}\hlstd{}\hlkwd{begin}\hlstd{}\hlsym{(),\ }\hlstd{std\textunderscore err}\hlsym{.}\hlstd{}\hlkwd{end}\hlstd{}\hlsym{(),\ }\hlstd{std\textunderscore err}\hlsym{.}\hlstd{}\hlkwd{begin}\hlstd{}\hlsym{(),\ }\hlstd{sqrt}\hlsym{);}\hspace*{\fill}\\
+\hlstd{\hspace*{\fill}\\
+}\hlstd{\ \ \ \ \ \ \ \ }\hlstd{Rcpp}\hlsym{::}\hlstd{List\ res\ }\hlsym{=\ }\hlstd{Rcpp}\hlsym{::}\hlstd{List}\hlsym{::}\hlstd{}\hlkwd{create}\hlstd{}\hlsym{(}\hlstd{Rcpp}\hlsym{::}\hlstd{}\hlkwd{Named}\hlstd{}\hlsym{(}\hlstd{}\hlstr{"coefficients"}\hlstd{}\hlsym{)\ =\ }\hlstd{coef}\hlsym{,}\hspace*{\fill}\\
+\hlstd{}\hlstd{\ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ }\hlstd{Rcpp}\hlsym{::}\hlstd{}\hlkwd{Named}\hlstd{}\hlsym{(}\hlstd{}\hlstr{"stderr"}\hlstd{}\hlsym{)\ =\ }\hlstd{std\textunderscore err}\hlsym{,}\hspace*{\fill}\\
+\hlstd{}\hlstd{\ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ }\hlstd{Rcpp}\hlsym{::}\hlstd{}\hlkwd{Named}\hlstd{}\hlsym{(}\hlstd{}\hlstr{"df"}\hlstd{}\hlsym{)\ =\ }\hlstd{n\ }\hlsym{{-}\ }\hlstd{k}\hlsym{);}\hspace*{\fill}\\
+\hlstd{\hspace*{\fill}\\
+}\hlstd{\ \ \ \ \ \ \ \ }\hlstd{}\hlslc{//\ free\ all\ the\ GSL\ vectors\ and\ matrices\ {-}{-}\ as\ these\ are\ really\ C\ data\ structures}\hspace*{\fill}\\
+\hlstd{}\hlstd{\ \ \ \ \ \ \ \ }\hlstd{}\hlslc{//\ we\ cannot\ take\ advantage\ of\ automatic\ memory\ management}\hspace*{\fill}\\
+\hlstd{}\hlstd{\ \ \ \ \ \ \ \ }\hlstd{coef}\hlsym{.}\hlstd{}\hlkwd{free}\hlstd{}\hlsym{();\ }\hlstd{cov}\hlsym{.}\hlstd{}\hlkwd{free}\hlstd{}\hlsym{();\ }\hlstd{y}\hlsym{.}\hlstd{}\hlkwd{free}\hlstd{}\hlsym{();\ }\hlstd{X}\hlsym{.}\hlstd{}\hlkwd{free}\hlstd{}\hlsym{();}\hspace*{\fill}\\
+\hlstd{\hspace*{\fill}\\
+}\hlstd{\ \ \ \ \ \ \ \ }\hlstd{}\hlkwa{return\ }\hlstd{res}\hlsym{;}\hlstd{\ \ \ \ }\hlsym{}\hlstd{}\hlslc{//\ return\ the\ result\ list\ to\ R}\hspace*{\fill}\\
+\hlstd{\hspace*{\fill}\\
+}\hlstd{\ \ }\hlstd{}\hlsym{\usebox{\hlsmallboxclosebrace}\ }\hlstd{}\hlkwa{catch}\hlstd{}\hlsym{(\ }\hlstd{std}\hlsym{::}\hlstd{exception\ }\hlsym{\&}\hlstd{ex\ }\hlsym{)\ \usebox{\hlsmallboxopenbrace}}\hspace*{\fill}\\
+\hlstd{}\hlstd{\ \ \ \ \ \ \ \ }\hlstd{}\hlkwd{forward\textunderscore exception\textunderscore to\textunderscore r}\hlstd{}\hlsym{(\ }\hlstd{ex\ }\hlsym{);}\hspace*{\fill}\\
+\hlstd{}\hlstd{\ \ }\hlstd{}\hlsym{\usebox{\hlsmallboxclosebrace}\ }\hlstd{}\hlkwa{catch}\hlstd{}\hlsym{(...)\ \usebox{\hlsmallboxopenbrace}}\hspace*{\fill}\\
+\hlstd{}\hlstd{\ \ \ \ \ \ \ \ }\hlstd{}\hlsym{::}\hlstd{}\hlkwd{Rf\textunderscore error}\hlstd{}\hlsym{(\ }\hlstd{}\hlstr{"c++\ exception\ (unknown\ reason)"}\hlstd{\ }\hlsym{);}\hspace*{\fill}\\
+\hlstd{}\hlstd{\ \ }\hlstd{}\hlsym{\usebox{\hlsmallboxclosebrace}}\hspace*{\fill}\\
+\hlstd{}\hlstd{\ \ }\hlstd{}\hlkwa{return\ }\hlstd{R\textunderscore NilValue}\hlsym{;\ }\hlstd{}\hlslc{//\ {-}Wall}\hspace*{\fill}\\
+\hlstd{}\hlsym{\usebox{\hlsmallboxclosebrace}}\hlstd{}\hspace*{\fill}\\
+\mbox{}
+\normalfont
+\end{Hchunk}\vspace{1em}
+\end{small}
+
+
+We first initialize a \textsl{RcppGSL} vector and matrix, each templated to
+the standard numeric type \texttt{double} (and the GSL supports other types
+ranging from lower precision floating point to signed and unsigned integers
+as well as complex numbers). We the reserve another vector and matrix to
+hold the resulting coefficient estimates as well as the estimate of the
+covariance matrix. Next, we allocate workspace using a GSL routine, fit the
+linear model and free the workspace. The next step involves extracting the
+diagonal element from the covariance matrix. We then employ a so-called
+iterator---a common \proglang{C++} idiom from the Standard Template Library
+(STL)---to iterate over the vector of diagonal and transforming it by
+applying the square root function to compute our standard error of the
+estimate. Finally we create a named list with the return value before we free
+temporary memory allocation (a step that has to be done because the
+underlying objects are really \proglang{C} objects conforming to the
+\pkg{GSL} interface and hence without the automatic memory management we
+could have with \proglang{C++} vector or matrix structures as used through
+the \pkg{Rcpp} package) and return the result to \proglang{R}.
+
+We should note that \pkg{RcppArmadillo} \citep{CRAN:RcppArmadillo} implements
+a matching \texttt{fastLm} function using the Armadillo library by
+\cite{Sanderson:2010:Armadillo}, and can do so with more compact code due to
+\proglang{C++} features.
+
+\section{Vectors}
+
+This section details the different vector represenations, starting with their
+definition inside the \pkg{GSL}. We then discuss our layering before showing
+how the two types map. A discussion of read-only `vector view' classes
+concludes the section.
+
+\subsection{\pkg{GSL} Vectors}
+
+\pkg{GSL} defines various vector types to manipulate one-dimensionnal
+data, similar to \proglang{R} arrays. For example the \verb|gsl_vector| and \verb|gsl_vector_int|
+structs are defined as:
+
+% < < vector_int,lang=cpp,size=small > > =
+% typedef struct{
+% size_t size;
+% size_t stride;
+% double * data;
+% gsl_block * block;
+% int owner;
+% } gsl_vector;
+
+% typedef struct {
+% size_t size;
+% size_t stride;
+% int * data;
+% gsl_block_int * block;
+% int owner;
+% }
+% gsl_vector_int;
+% @
+
+\begin{small}
+\begin{Hchunk}
+\noindent
+\ttfamily
+\hlstd{}\hlkwc{typedef\ }\hlstd{}\hlkwb{struct}\hlstd{}\hlsym{\usebox{\hlsmallboxopenbrace}}\hspace*{\fill}\\
+\hlstd{}\hlstd{\ \ }\hlstd{}\hlkwb{size\textunderscore t\ }\hlstd{size}\hlsym{;}\hspace*{\fill}\\
+\hlstd{}\hlstd{\ \ }\hlstd{}\hlkwb{size\textunderscore t\ }\hlstd{stride}\hlsym{;}\hspace*{\fill}\\
+\hlstd{}\hlstd{\ \ }\hlstd{}\hlkwb{double\ }\hlstd{}\hlsym{{*}\ }\hlstd{data}\hlsym{;}\hspace*{\fill}\\
+\hlstd{}\hlstd{\ \ }\hlstd{gsl\textunderscore block\ }\hlsym{{*}\ }\hlstd{block}\hlsym{;}\hspace*{\fill}\\
+\hlstd{}\hlstd{\ \ }\hlstd{}\hlkwb{int\ }\hlstd{owner}\hlsym{;}\hspace*{\fill}\\
+\hlstd{}\hlsym{\usebox{\hlsmallboxclosebrace}\ }\hlstd{gsl\textunderscore vector}\hlsym{;}\hspace*{\fill}\\
+\hlstd{}\hspace*{\fill}\\
+\hlkwc{typedef\ }\hlstd{}\hlkwb{struct\ }\hlstd{}\hlsym{\usebox{\hlsmallboxopenbrace}}\hspace*{\fill}\\
+\hlstd{}\hlstd{\ \ }\hlstd{}\hlkwb{size\textunderscore t\ }\hlstd{size}\hlsym{;}\hspace*{\fill}\\
+\hlstd{}\hlstd{\ \ }\hlstd{}\hlkwb{size\textunderscore t\ }\hlstd{stride}\hlsym{;}\hspace*{\fill}\\
+\hlstd{}\hlstd{\ \ }\hlstd{}\hlkwb{int\ }\hlstd{}\hlsym{{*}\ }\hlstd{data}\hlsym{;}\hspace*{\fill}\\
+\hlstd{}\hlstd{\ \ }\hlstd{gsl\textunderscore block\textunderscore int\ }\hlsym{{*}\ }\hlstd{block}\hlsym{;}\hspace*{\fill}\\
+\hlstd{}\hlstd{\ \ }\hlstd{}\hlkwb{int\ }\hlstd{owner}\hlsym{;}\hspace*{\fill}\\
+\hlstd{}\hlsym{\usebox{\hlsmallboxclosebrace}}\hspace*{\fill}\\
+\hlstd{gsl\textunderscore vector\textunderscore int}\hlsym{;}\hlstd{}\hspace*{\fill}\\
+\mbox{}
+\normalfont
+\end{Hchunk}\vspace{1em}
+\end{small}
+
+
+A typical use of the \verb|gsl_vector| struct is given below:
+
+% < <vector_free,lang=cpp,size=small> > =
+% int i;
+% gsl_vector * v = gsl_vector_alloc (3); // allocate a gsl_vector of size 3
+
+% for (i = 0; i < 3; i++) { // fill the vector
+% gsl_vector_set (v, i, 1.23 + i);
+% }
+
+% double sum = 0.0 ; // access elements
+% for (i = 0; i < 3; i++) {
+% sum += gsl_vector_set( v, i ) ;
+% }
+
+% gsl_vector_free (v); // free the memory
+% @
+
+\begin{small}
+\begin{Hchunk}
+\noindent
+\ttfamily
+\hlstd{}\hlkwb{int\ }\hlstd{i}\hlsym{;}\hspace*{\fill}\\
+\hlstd{gsl\textunderscore vector\ }\hlsym{{*}\ }\hlstd{v\ }\hlsym{=\ }\hlstd{}\hlkwd{gsl\textunderscore vector\textunderscore alloc\ }\hlstd{}\hlsym{(}\hlstd{}\hlnum{3}\hlstd{}\hlsym{);}\hlstd{\ \ }\hlsym{}\hlstd{}\hlslc{//\ allocate\ a\ gsl\textunderscore vector\ of\ size\ 3}\hspace*{\fill}\\
+\hlstd{}\hspace*{\fill}\\
+\hlkwa{for\ }\hlstd{}\hlsym{(}\hlstd{i\ }\hlsym{=\ }\hlstd{}\hlnum{0}\hlstd{}\hlsym{;\ }\hlstd{i\ }\hlsym{\usebox{\hlsmallboxlessthan}\ }\hlstd{}\hlnum{3}\hlstd{}\hlsym{;\ }\hlstd{i}\hlsym{++)\ \usebox{\hlsmallboxopenbrace}}\hlstd{\ \ \ \ \ \ \ \ \ \ \ \ \ \ \ }\hlsym{}\hlstd{}\hlslc{//\ fill\ the\ vector}\hspace*{\fill}\\
+\hlstd{}\hlstd{\ \ }\hlstd{}\hlkwd{gsl\textunderscore vector\textunderscore set\ }\hlstd{}\hlsym{(}\hlstd{v}\hlsym{,\ }\hlstd{i}\hlsym{,\ }\hlstd{}\hlnum{1.23\ }\hlstd{}\hlsym{+\ }\hlstd{i}\hlsym{);}\hspace*{\fill}\\
+\hlstd{}\hlsym{\usebox{\hlsmallboxclosebrace}}\hspace*{\fill}\\
+\hlstd{}\hspace*{\fill}\\
+\hlkwb{double\ }\hlstd{sum\ }\hlsym{=\ }\hlstd{}\hlnum{0.0\ }\hlstd{}\hlsym{;}\hlstd{\ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ }\hlsym{}\hlstd{}\hlslc{//\ access\ elements}\hspace*{\fill}\\
+\hlstd{}\hlkwa{for\ }\hlstd{}\hlsym{(}\hlstd{i\ }\hlsym{=\ }\hlstd{}\hlnum{0}\hlstd{}\hlsym{;\ }\hlstd{i\ }\hlsym{\usebox{\hlsmallboxlessthan}\ }\hlstd{}\hlnum{3}\hlstd{}\hlsym{;\ }\hlstd{i}\hlsym{++)\ \usebox{\hlsmallboxopenbrace}}\hspace*{\fill}\\
+\hlstd{}\hlstd{\ \ }\hlstd{sum\ }\hlsym{+=\ }\hlstd{}\hlkwd{gsl\textunderscore vector\textunderscore set}\hlstd{}\hlsym{(\ }\hlstd{v}\hlsym{,\ }\hlstd{i\ }\hlsym{)\ ;}\hspace*{\fill}\\
+\hlstd{}\hlsym{\usebox{\hlsmallboxclosebrace}}\hspace*{\fill}\\
+\hlstd{}\hspace*{\fill}\\
+\hlkwd{gsl\textunderscore vector\textunderscore free\ }\hlstd{}\hlsym{(}\hlstd{v}\hlsym{);}\hlstd{\ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ }\hlsym{}\hlstd{}\hlslc{//\ free\ the\ memory}\hlstd{}\hspace*{\fill}\\
+\mbox{}
+\normalfont
+\end{Hchunk}\vspace{1em}
+\end{small}
+
+\subsection{RcppGSL::vector}
+
+\pkg{RcppGSL} defines the template \texttt{RcppGSL::vector<T>} to manipulate
+\verb|gsl_vector| pointers taking advantage of C++ templates. Using this
+template type, the previous example now becomes:
+
+% < < vector_sum,lang=cpp,size=small > > =
+% int i;
+% RcppGSL::vector<double> v(3); // allocate a gsl_vector of size 3
+
+% for (i = 0; i < 3; i++) { // fill the vector
+% v[i] = 1.23 + i ;
+% }
+
+% double sum = 0.0 ; // access elements
+% for (i = 0; i < 3; i++) {
+% sum += v[i] ;
+% }
+
+% v.free() ; // free the memory
+% @
+
+\begin{small}
+\begin{Hchunk}
+\noindent
+\ttfamily
+\hlstd{}\hlkwb{int\ }\hlstd{i}\hlsym{;}\hspace*{\fill}\\
+\hlstd{RcppGSL}\hlsym{::}\hlstd{vector}\hlsym{\usebox{\hlsmallboxlessthan}}\hlstd{}\hlkwb{double}\hlstd{}\hlsym{\usebox{\hlsmallboxgreaterthan}\ }\hlstd{}\hlkwd{v}\hlstd{}\hlsym{(}\hlstd{}\hlnum{3}\hlstd{}\hlsym{);}\hlstd{\ \ \ \ \ \ \ \ \ \ \ }\hlsym{}\hlstd{}\hlslc{//\ allocate\ a\ gsl\textunderscore vector\ of\ size\ 3}\hspace*{\fill}\\
+\hlstd{}\hspace*{\fill}\\
+\hlkwa{for\ }\hlstd{}\hlsym{(}\hlstd{i\ }\hlsym{=\ }\hlstd{}\hlnum{0}\hlstd{}\hlsym{;\ }\hlstd{i\ }\hlsym{\usebox{\hlsmallboxlessthan}\ }\hlstd{}\hlnum{3}\hlstd{}\hlsym{;\ }\hlstd{i}\hlsym{++)\ \usebox{\hlsmallboxopenbrace}}\hlstd{\ \ \ \ \ \ \ \ \ \ \ \ \ \ \ }\hlsym{}\hlstd{}\hlslc{//\ fill\ the\ vector}\hspace*{\fill}\\
+\hlstd{}\hlstd{\ \ }\hlstd{v}\hlsym{{[}}\hlstd{i}\hlsym{{]}\ =\ }\hlstd{}\hlnum{1.23\ }\hlstd{}\hlsym{+\ }\hlstd{i\ }\hlsym{;}\hspace*{\fill}\\
+\hlstd{}\hlsym{\usebox{\hlsmallboxclosebrace}}\hspace*{\fill}\\
+\hlstd{}\hspace*{\fill}\\
+\hlkwb{double\ }\hlstd{sum\ }\hlsym{=\ }\hlstd{}\hlnum{0.0\ }\hlstd{}\hlsym{;}\hlstd{\ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ }\hlsym{}\hlstd{}\hlslc{//\ access\ elements}\hspace*{\fill}\\
+\hlstd{}\hlkwa{for\ }\hlstd{}\hlsym{(}\hlstd{i\ }\hlsym{=\ }\hlstd{}\hlnum{0}\hlstd{}\hlsym{;\ }\hlstd{i\ }\hlsym{\usebox{\hlsmallboxlessthan}\ }\hlstd{}\hlnum{3}\hlstd{}\hlsym{;\ }\hlstd{i}\hlsym{++)\ \usebox{\hlsmallboxopenbrace}}\hspace*{\fill}\\
+\hlstd{}\hlstd{\ \ }\hlstd{sum\ }\hlsym{+=\ }\hlstd{v}\hlsym{{[}}\hlstd{i}\hlsym{{]}\ ;}\hspace*{\fill}\\
+\hlstd{}\hlsym{\usebox{\hlsmallboxclosebrace}}\hspace*{\fill}\\
+\hlstd{\hspace*{\fill}\\
+v}\hlsym{.}\hlstd{}\hlkwd{free}\hlstd{}\hlsym{()\ ;}\hlstd{\ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ }\hlsym{}\hlstd{}\hlslc{//\ free\ the\ memory}\hlstd{}\hspace*{\fill}\\
+\mbox{}
+\normalfont
+\end{Hchunk}\vspace{1em}
+\end{small}
+
+The class \texttt{RcppGSL::vector<double>} is a smart pointer, that can be used
+anywhere where a raw pointer \verb|gsl_vector| can be used, such as the
+\verb|gsl_vector_set| and \verb|gsl_vector_get| functions above.
+
+Beyond the convenience of a nicer syntax for allocation and release of
+memory, the \texttt{RcppGSL::vector} template faciliates interchange of
+\pkg{GSL} vectors with \pkg{Rcpp} objects, and hence \pkg{R} objects. The
+following example defines a \texttt{.Call} compatible function called
+\verb|sum_gsl_vector_int| that operates on a \verb|gsl_vector_int| through
+the \texttt{RcppGSL::vector<int>} template specialization:
+
+% < <macro,lang=cpp,size=small > > =
+% RCPP_FUNCTION_1( int, sum_gsl_vector_int, RcppGSL::vector<int> vec){
+% int res = std::accumulate( vec.begin(), vec.end(), 0 ) ;
+% vec.free() ; // we need to free vec after use
+% return res ;
+% }
+% @
+
+\begin{small}
+\begin{Hchunk}
+\noindent
+\ttfamily
+\hlstd{}\hlkwd{RCPP\textunderscore FUNCTION\textunderscore 1}\hlstd{}\hlsym{(\ }\hlstd{}\hlkwb{int}\hlstd{}\hlsym{,\ }\hlstd{sum\textunderscore gsl\textunderscore vector\textunderscore int}\hlsym{,\ }\hlstd{RcppGSL}\hlsym{::}\hlstd{vector}\hlsym{\usebox{\hlsmallboxlessthan}}\hlstd{}\hlkwb{int}\hlstd{}\hlsym{\usebox{\hlsmallboxgreaterthan}\ }\hlstd{vec}\hlsym{)\usebox{\hlsmallboxopenbrace}}\hspace*{\fill}\\
+\hlstd{}\hlstd{\ \ }\hlstd{}\hlkwb{int\ }\hlstd{res\ }\hlsym{=\ }\hlstd{std}\hlsym{::}\hlstd{}\hlkwd{accumulate}\hlstd{}\hlsym{(\ }\hlstd{vec}\hlsym{.}\hlstd{}\hlkwd{begin}\hlstd{}\hlsym{(),\ }\hlstd{vec}\hlsym{.}\hlstd{}\hlkwd{end}\hlstd{}\hlsym{(),\ }\hlstd{}\hlnum{0\ }\hlstd{}\hlsym{)\ ;}\hspace*{\fill}\\
+\hlstd{}\hlstd{\ \ }\hlstd{vec}\hlsym{.}\hlstd{}\hlkwd{free}\hlstd{}\hlsym{()\ ;}\hlstd{\ \ }\hlsym{}\hlstd{}\hlslc{//\ we\ need\ to\ free\ vec\ after\ use}\hspace*{\fill}\\
+\hlstd{}\hlstd{\ \ }\hlstd{}\hlkwa{return\ }\hlstd{res\ }\hlsym{;}\hspace*{\fill}\\
+\hlstd{}\hlsym{\usebox{\hlsmallboxclosebrace}}\hlstd{}\hspace*{\fill}\\
+\mbox{}
+\normalfont
+\end{Hchunk}\vspace{1em}
+\end{small}
+
+
+The function can then simply be called from \proglang{R} :
+
+<<inlineex1,results=hide,echo=FALSE>>=
+fx <- cxxfunction(
+ list( sum_gsl_vector_int = signature( vec_ = "integer" ) ),
+ c( sum_gsl_vector_int = '
+ RcppGSL::vector<int> vec = as< RcppGSL::vector<int> >(vec_) ;
+ int res = std::accumulate( vec.begin(), vec.end(), 0 ) ;
+ vec.free() ; // we need to free vec after use
+ return wrap( res ) ;
+' ), plugin = "RcppGSL" )
+<<callinlineex1,size=small>>=
+.Call( "sum_gsl_vector_int", 1:10 )
+@
+
+A second example shows a simple function that grabs elements of an
+R list as \verb|gsl_vector| objects using implicit conversion mechanisms
+of \pkg{Rcpp}
+
+%< < example2,lang=cpp,size=small > > =
+% RCPP_FUNCTION_1( double, gsl_vector_sum_2, Rcpp::List data ){
+% // grab "x" as a gsl_vector through the RcppGSL::vector<double> class
+% RcppGSL::vector<double> x = data["x"] ;
+
+% // grab "y" as a gsl_vector through the RcppGSL::vector<int> class
+% RcppGSL::vector<int> y = data["y"] ;
+% double res = 0.0 ;
+% for( size_t i=0; i< x->size; i++){
+% res += x[i] * y[i] ;
+% }
+
+% // as usual with GSL, we need to explicitely free the memory
+% x.free() ;
+% y.free() ;
+
+% // return the result
+% return res ;
+% }
+% @
+
+\begin{small}
+\begin{Hchunk}
+\noindent
+\ttfamily
+\hlstd{}\hlkwd{RCPP\textunderscore FUNCTION\textunderscore 1}\hlstd{}\hlsym{(\ }\hlstd{}\hlkwb{double}\hlstd{}\hlsym{,\ }\hlstd{gsl\textunderscore vector\textunderscore sum\textunderscore 2}\hlsym{,\ }\hlstd{Rcpp}\hlsym{::}\hlstd{List\ data\ }\hlsym{)\usebox{\hlsmallboxopenbrace}}\hspace*{\fill}\\
+\hlstd{}\hlstd{\ \ }\hlstd{}\hlslc{//\ grab\ "x"\ as\ a\ gsl\textunderscore vector\ through\ the\ RcppGSL::vector\usebox{\hlsmallboxlessthan}double\usebox{\hlsmallboxgreaterthan}\ class}\hspace*{\fill}\\
+\hlstd{}\hlstd{\ \ }\hlstd{RcppGSL}\hlsym{::}\hlstd{vector}\hlsym{\usebox{\hlsmallboxlessthan}}\hlstd{}\hlkwb{double}\hlstd{}\hlsym{\usebox{\hlsmallboxgreaterthan}\ }\hlstd{x\ }\hlsym{=\ }\hlstd{data}\hlsym{{[}}\hlstd{}\hlstr{"x"}\hlstd{}\hlsym{{]}\ ;}\hspace*{\fill}\\
+\hlstd{\hspace*{\fill}\\
+}\hlstd{\ \ }\hlstd{}\hlslc{//\ grab\ "y"\ as\ a\ gsl\textunderscore vector\ through\ the\ RcppGSL::vector\usebox{\hlsmallboxlessthan}int\usebox{\hlsmallboxgreaterthan}\ class}\hspace*{\fill}\\
+\hlstd{}\hlstd{\ \ }\hlstd{RcppGSL}\hlsym{::}\hlstd{vector}\hlsym{\usebox{\hlsmallboxlessthan}}\hlstd{}\hlkwb{int}\hlstd{}\hlsym{\usebox{\hlsmallboxgreaterthan}\ }\hlstd{y\ }\hlsym{=\ }\hlstd{data}\hlsym{{[}}\hlstd{}\hlstr{"y"}\hlstd{}\hlsym{{]}\ ;}\hspace*{\fill}\\
+\hlstd{}\hlstd{\ \ }\hlstd{}\hlkwb{double\ }\hlstd{res\ }\hlsym{=\ }\hlstd{}\hlnum{0.0\ }\hlstd{}\hlsym{;}\hspace*{\fill}\\
[TRUNCATED]
To get the complete diff run:
svnlook diff /svnroot/rcpp -r 4353
More information about the Rcpp-commits
mailing list