Publications by romain francois

new R package : bibtex

11.12.2009

I’ve pushed to CRAN the package bibtex package The package defines the read.bib function that reads a file in the bibtex format. The code is based on bibparse The read.bib function generates an object of class citationList, just like utils::citation Related To leave a comment for the author, please follow the link and comment on their blog: ...

674 sym

CPP package: exposing C++ objects

22.12.2009

I’ve just started working on the new package CPP, as usual the project is maintained in r-forge. The package aims at exposing C++ classes at the R level, starting from classes from the c++ standard template library. key to the package is the CPP function (much inspired from the J function of rJava). The CPP function builds an S4 object of class...

2389 sym R (352 sym/2 pcs)

C++ exceptions at the R level

29.12.2009

I’ve recently offered an extra set of hands to Dirk to work on the Rcpp package, this serves a good excuse to learn more about C++ Exception management was quite high on my list. C++ has nice exception handling (well not as nice as java, but nicer than C). With previous versions of Rcpp, the idiom was to wrap up everything in a try/catch block...

2197 sym R (454 sym/2 pcs)

R Journal, Volume 1/2, December 2009

07.01.2010

The issue 1/2 of the R Journal has been published. It features an article that I co-authored with Spencer Graves and Sundar Dorai-Raj about the sospackage. Related To leave a comment for the author, please follow the link and comment on their blog: Romain Francois, Professional R Enthusiast. R-bloggers.com offers daily e-mail updates about R...

581 sym

External pointers with Rcpp

08.01.2010

One of the new features of Rcpp is the XPtr class template, which lets you treat an R external pointer as a regular pointer. For more information on external pointers, see Writing R extensions. To use them, first we need a pointer to some C++ data structure, we’ll use a pointer to a vector<int> : /* creating a pointer to a vector<int> */ std:...

2011 sym R (2365 sym/7 pcs)

Rcpp 0.7.2

13.01.2010

Rcpp 0.7.2 is out, checkout Dirk’s blog for details selected highlights from this new version: character vectors if one wants to mimic this R code in C > x <- c( "foo", "bar" ) one ends up with this : SEXP x = PROTECT( allocVector( STRSXP, 2) ) ; SET_STRING_ELT( x, 0, mkChar( "foo" ) ) ; SET_STRING_ELT( x, 1, mkChar( "bar" ) ) ; UNPROTECT(1...

990 sym R (1075 sym/9 pcs)

RProtoBuf: protocol buffers for R

04.02.2010

We (Dirk and I) released the initial version of our package RProtoBuf to CRAN this week. This packages brings google’s protocol buffers to R I invite you to check out the main page for protobuf to find the language definition for protocol buffers as well as tutorial for officially (i.e. by google) supported languages (python, c++ and java) as w...

1707 sym R (491 sym/5 pcs)

Rcpp 0.7.5

09.02.2010

Dirk released Rcpp 0.7.5 yesterday The main thing is the smarter wrap function that now uses techniques of type traits and template meta-programming to have a compile time guess at whether an object is wrappable, and how to do it. Currently wrappable types are : primitive types : int, double, Rbyte, Rcomplex std::string STL containers such as s...

1348 sym R (2742 sym/2 pcs)

highlight 0.1-5

13.02.2010

I’ve pushed the version 0.1-5 of highlight to CRAN, it should be available in a couple of days. This version fixes highlighting of code when one wants to display the prompt and the continue prompt. For example, this code : rnorm(10, mean = 5) runif(5) gets highlighted like this: using this code: > highlight( "/tmp/test.R", renderer=rend...

850 sym R (140 sym/2 pcs)

Rcpp 0.7.7

14.02.2010

A good 2 days after 0.7.6 was released, here comes Rcpp 0.7.7. The reason for this release is that a subtle bug installed itself and we did not catch it in time The new version also includes two new class templates : unary_call and binary_call that help integration of calls (e.g. Rcpp::Language objects) with STL algorithms. For example here is ho...

865 sym R (51 sym/1 pcs)