Dirk Eddelbuettel Thinking inside the box
 
Mon, 13 May 2013

RcppArmadillo 0.3.820
Conrad rolled up a new Armadillo release 3.820 (following two minor fix release in the 0.3.810 series of which we packaged the one that was relevant for us). This new version is now out in a release 0.3.820 of RcppArmadillo which is already on CRAN and in Debian.

The summary of the main changes follows:

Changes in RcppArmadillo version 0.3.820 (2013-05-12)

  • Upgraded to Armadillo release Version 3.820 (Mt Cootha)

    • faster as_scalar() for compound expressions

    • faster transpose of small vectors

    • faster matrix-vector product for small vectors

    • faster multiplication of small fixed size matrices

Courtesy of CRANberries, there is also a diffstat report for the most recent release As always, more detailed information is on the RcppArmadillo page. Questions, comments etc should go to the rcpp-devel mailing list off the R-Forge page.

/code/rcpp | permanent link

Sun, 12 May 2013

Recent Rcpp talks at U of C and MCW
A couple of days ago, I had an opportunity to give a guest lecture on our Rcpp package for R and C++ integration. This was in CMSC 12300 Computer Science with Applications-3 in the Department of Computer Science at University of Chicago. The course is the final part of a three term sequence introducing students to data-centric work in R, Python, Java and C++. I tried to keep it brief and engaging in order to motivate the why or R/C++ integration while providing plenry of useful examples.

And yesterday I got to spend a day giving an invited day-long workshop at the Medical College of Wisconsin as part of a two-day R workshop sponsored by the Milwaukee Chapter of the American Statistical Assocation as well as the CTSI and PCOR centers at the Medical College of Wisconsin. In the workshop, I followed the previously-used setup of four parts on introduction, Rcpp details, advanced topics and last-but-not-least applications, but also updated and extended to more recent topics.

Pdf slides from both events are now on my presentations page.

/code/rcpp | permanent link

Sat, 20 Apr 2013

RcppArmadillo 0.3.810.0
A new Armadillo release 3.810.0 by Conrad appeared yesterday, and was wrapped up in a new release 0.3.810.0 of RcppArmadillo. Upstream changes bring FFT support as well as more Sparse matrix constructors, and we have an improvement to the sample() function contributed by Christian Gunning.

As RcppArmadillo is used by an increasing number of packages---on CRAN alone, we find 34 direct dependencies---I also added the package to Debian and upload there in parallel.

The summary of the main changes follows:

Changes in RcppArmadillo version 0.3.810.0 (2013-04-19)

  • Upgraded to Armadillo release Version 3.810.0 (Newell Highway)

    • added fast Fourier transform: fft()

    • added handling of .imbue() and .transform() by submatrices and subcubes

    • added batch insertion constructors for sparse matrices

    • minor fix for multiplication of complex sparse matrices

  • Updated sample() function and test again contributed by Christian Gunning

Courtesy of CRANberries, there is also a diffstat report for the most recent release As always, more detailed information is on the RcppArmadillo page. Questions, comments etc should go to the rcpp-devel mailing list off the R-Forge page.

/code/rcpp | permanent link

Sat, 23 Mar 2013

Rcpp 0.10.3
A new relase 0.10.3 of Rcpp is now on CRAN and in Debian.

This is the fourth release in the 0.10.* series, and further extends and solidifies the excellent Rcpp attributes. A few other bugs were fixed as well, and support for wide character strings has been added.

We once again tested this fairly rigorously by checking against 86 of the 100 CRAN packages depending on Rcpp. All of these passed. So we do not expect any issues with dependent packages, but one never knows.

The complete NEWS entry for 0.10.3 is below; more details are in the ChangeLog file in the package and on the Rcpp Changelog page.

Changes in Rcpp version 0.10.3 (2013-03-23)

  • Changes in R code:

    • Prevent build failures on Windowsn when Rcpp is installed in a library path with spaces (transform paths in the same manner that R does before passing them to the build system).

  • Changes in Rcpp attributes:

    • Rcpp modules can now be used with sourceCpp

    • Standalone roxygen chunks (e.g. to document a class) are now transposed into RcppExports.R

    • Added Rcpp::plugins attribute for binding directly to inline plugins. Plugins can be registered using the new registerPlugin function.

    • Added built-in cpp11 plugin for specifying the use of C++11 in a translation unit

    • Merge existing values of build related environment variables for sourceCpp

    • Add global package include file to RcppExports.cpp if it exists

    • Stop with an error if the file name passed to sourceCpp has spaces in it

    • Return invisibly from void functions

    • Ensure that line comments invalidate block comments when parsing for attributes

    • Eliminated spurious empty hello world function definition in Rcpp.package.skeleton

  • Changes in Rcpp API:

    • The very central use of R API R_PreserveObject and R_ReleaseObject has been replaced by a new system based on the functions Rcpp_PreserveObject, Rcpp_ReleaseObject and Rcpp_ReplaceObject which shows better performance and is implemented using a generic vector treated as a stack instead of a pairlist in the R implementation. However, as this preserve / release code is still a little rough at the edges, a new #define is used (in config.h) to disable it for now.

    • Platform-dependent code in Timer.cpp now recognises a few more BSD variants thanks to contributed defined() test suggestions

    • Support for wide character strings has been added throughout the API. In particular String, CharacterVector, wrap and as are aware of wide character strings

Thanks to CRANberries, you can also look at a diff to the previous release 0.10.2. As always, even fuller details are on the Rcpp Changelog page and the Rcpp page which also leads to the downloads, the browseable doxygen docs and zip files of doxygen output for the standard formats. A local directory has source and documentation too. Questions, comments etc should go to the rcpp-devel mailing list off the R-Forge page

/code/rcpp | permanent link

Tue, 12 Mar 2013

Rcpp master class in New York last weekend
On Saturday I had the opportunity to teach another one-day master class on Rcpp. The class had been organized by Jared Lander, and organized very well I might add.

The weekend started with a slight disappointment. I had taken Friday off, and hoped to reach NY by early afternoon to join JJ there, and to spend the afternoon with the RStan team. However, the tail end of last week's snowstorm made it such that we both got to Columbia's stats department closer to 6pm rather than 1pm, and half the team had left. Dang. Very frustrating travel experience. We salvaged the evening by gabbing over a cold beverage or two, before sharing some sacred New York pizza with Wes McKinney and Jared.

The class itself on Saturday went quite well. With JJ on deck, we were able to have every participant log into an EC2-hosted instance of RStudio Server, which worked very well for usage examples of Rcpp. It has been almost a year since I last taught the class, and many exciting things--such as Rcpp attributes, added by JJ himself--have appeared, which made it extra fun. Participants were rather kind with praise. Either they really liked it, or they really are hard-nosed New Yorkers who manage to lie to my face without me noticing.

We ended the day with some hard-earned cold beverages, followed by some dinner at Sylvia's (as tweeted by Jared) followed by more drinks. Ended up a little past my usual bedtime, but I managed to get out and enjoy a lovely 6.5 miles run across Central Park the next morning before leaving town.

All in all, a very nice weekend, the travel horror of Friday notwithstanding. And who know, maybe we'll just do it again another time...

/code/rcpp | permanent link

RcppArmadillo 0.3.800.1
Conrad released a first bug-fix release 3.800.1 of Armadillo earlier today. This has been wrapped up in release 0.3.800.1 of RcppArmadillo as usual. This release also contains a very nice function sample() (contributed by Christian Gunning) which provides sampling (with or without replacement) at the C++ level modeled after what we are used to in R itself. We also refactored the unit tests into just two compilation units to speed testing up a little.

The summary of the main changes follows:

Changes in RcppArmadillo version 0.3.800.1 (2013-03-12)

  • Upgraded to Armadillo release Version 3.800.1 (Miami Beach)

    • workaround for a bug in ATLAS 3.8 on 64 bit systems

    • faster matrix-vector multiply for small matrices

  • Added new sample() function and tests contributed by Christian Gunning

  • Refactored unit testing code for faster unit test performance

Courtesy of CRANberries, there is also a diffstat report for the most recent release As always, more detailed information is on the RcppArmadillo page. Questions, comments etc should go to the rcpp-devel mailing list off the R-Forge page.

/code/rcpp | permanent link

Sat, 02 Mar 2013

RcppArmadillo 0.3.800.0
A new Armadillo version 3.800.0 is now out. Conrad picked a new numbering scheme to coincide with the relicensing from LGPL to MPL 2.0. The new version 0.3.800.0 of the corresponding RcppArmadillo package (which still uses GPL 2 or later) is now on CRAN. It also contains the updated version of our paper as the package vignette.

The summary of the main changes follows:

Changes in RcppArmadillo version 0.3.800.0 (2013-03-01)

  • Upgraded to Armadillo release Version 3.800.0 (Miami Beach)

    • Armadillo is now licensed using the Mozilla Public License 2.0

    • added .imbue() for filling a matrix/cube with values provided by a functor or lambda expression

    • added .swap() for swapping contents with another matrix

    • added .transform() for transforming a matrix/cube using a functor or lambda expression

    • added round() for rounding matrix elements towards nearest integer

    • faster find()

    • fixes for handling non-square matrices by qr() and qr_econ()

    • minor fixes for handling empty matrices

    • reduction of pedantic compiler warnings

  • Updated vignette to paper now in press at CSDA

  • Added CITATION file with reference to CSDA paper

Courtesy of CRANberries, there is also a diffstat report for the most recent release As always, more detailed information is on the RcppArmadillo page. Questions, comments etc should go to the rcpp-devel mailing list off the R-Forge page.

/code/rcpp | permanent link

Sat, 23 Feb 2013

Two papers about RcppEigen and RcppArmadillo published
Two papers got published recently. The first one is Bates and Eddelbuettel (2013). It is titled Fast and Elegant Numerical Linear Algebra Using the RcppEigen Package, and provides a pretty thorough introduction to our RcppEigen package which uses Rcpp to provide access to the Eigen C++ template library from GNU R. The paper is out as Volume 50, Issue 5 at the (all electronic, open, and generally awesome) Journal of Statistical Software. A bibtex entry is available.

The second paper is Eddelbuettel and Sanderson (2013). This one is titled RcppArmadillo: Accelerating R with high-performance C++ linear algebra and introduces the RcppArmadillo package which brings Conrad Sanderson's Armadillo C++ template library to GNU R by deploying Rcpp. The paper is currently "in press" at Computational Statistics & Data Analysis but the DOI 10.1016/j.csda.2013.02.005 will remain once a volume and issue is assigned by CSDA.

Preprints of both papers are available via my papers page, and as vignettes in the corresponding packages.

The upcoming Rcpp class in New York will feature Rcpp, RcppArmadillo and RcppEigen. Space is still available.

/code/rcpp | permanent link

Wed, 20 Feb 2013

RcppArmadillo 0.3.6.3
A new Armadillo version 3.6.3 came out this morning, and the corresponding RcppArmadillo version is now on CRAN. Changes are incremental:

Changes in RcppArmadillo version 0.3.6.3 (2013-02-20)

  • Upgraded to Armadillo release Version 3.6.3

    • faster find()

    • minor fix for non-contiguous submatrix views to handle empty vectors of indices

    • reduction of pedantic compiler warnings

Courtesy of CRANberries, there is also a diffstat report for the most recent release As always, more detailed information is on the RcppArmadillo page. Questions, comments etc should go to the rcpp-devel mailing list off the R-Forge page.

/code/rcpp | permanent link

Mon, 18 Feb 2013

New Rcpp master class scheduled for New York
A new Rcpp master class is scheduled for March 9 in New York. The format will an updated version of the one-day workshops I have given at the University of Rochester in 2010, in San Franciso in 2011 (organised by Revolution Analytics) and at the UseR! conference in 2012.

The style will be hands-on, with numerous concrete examples and solid coverage of most aspects of Rcpp and related packages. As before, about six hours of instruction, split into four sessions of around ninety minutes focussing (loosely) on motivation/intro, core parts, extensions and applications. This should leave ample time for informal discussions and Q+A---as well as for lunch and coffee breaks---for a total of eight hours in the classroom.

This is being put together in New York with the help of Jared Lander, and we will have some technical assistance from RStudio in order to use their EC2 farm for exercises with Rcpp.

Registrations details are available here; information about other Rcpp events is also available.

Feel free to contact me or Jared at our usual email addresses with questions.

/code/rcpp | permanent link

Tue, 05 Feb 2013

A book about Rcpp
Some little birds had already been whispering about it, but I didn't want to jinx it and told myself I would wait with an announcement until the booksellers have (at least) placeholder pages. And as I learned from Duncan Murdoch via email earlier today, at least Chapters/Indigo had a page up, presumably scraped from the publisher page, so here it goes:

I have in fact handed a complete draft of my book about Seamless R and C++ Integration with Rcpp to Springer a few weeks ago. With a bit of luck on the production side, we could be seeing physical copies by May of a new title in their popular UseR! Series series.

And to the slowly growing new Rcpp site, I have added a a formal page about the Rcpp book where one can find information about it, including a link to the Springer page, links to a few bookseller's pages --- as well as a few wonderfully flattering endorsements. Eventually, errata and other support material should be available via this page too. Can't wait til I hold a physical copy in hand...

/code/rcpp | permanent link

New Rcpp page on upcoming events -- including Master Class in New York
Lots of exciting things are happening with and around Rcpp. I just added a new page about Upcoming Events to the recently-created Rcpp site. This events page has lots to cover: an upcoming talk at Columbia on March 8 (details still TBD), a day-long workshop in New York on March 9, a possible participation at a CERN / ROOT conference in Switzerland on May 11-14, an upcoming talk in May in Milwaukee, and last but not least the tutorial by Romain and Hadley at UseR! 2013 in Spain. Phew!

With that, a few quick words about the upcoming master class in New York. It will be a full day, covering an introduction and motivation, details about the core data types, tools for working with and and extending Rcpp and of course applications galore, including RcppArmadillo and RInside. I have done the same one day class format a few times before, most recently (with Revolution Analytics) in San Francisco in late 2011, and also as a two-part seminar at UseR! 2012. This time, we plan on providing cloud-hosted RStudio instances for participants. Better still, RStudio's own JJ Allaire will be on deck as well for RStudio --- and Rcpp Attributes --- questions.

Details and registration information for the New York class are at this page.

/code/rcpp | permanent link

Sun, 03 Feb 2013

The Rcpp Gallery and my Seinfeld Streak
A good three weeks ago, we introduced the Rcpp Gallery. While this is a joint effort by several of us on the Rcpp team, the backend was conceived and implemented entirely by JJ who also bootstrapped it with same first content, drawing on posts by Hadley, Romain and myself. As the How to contribute page makes plain, this is all backed by GitHub and all logs are public anyway.

So after it was up and working, JJ and I refined the look and feel, and I started to add more content so that would have something by the time the initial announcement came around. A few years I read about an (attributed) secret to Seinfeld's producitivity: "Don't break the chain". Just keep writing, and write every day.

I made my goal of a post every day for just over a month, and created this sequences: (20 Dec) simulating-pi, (21 Dec) vector-minimum, (22 Dec) gsl-colnorm-example, (23 Dec) fibonacci-sequence, (24 Dec) random-number-generation, (25 Dec) armadillo-sparse-matrix, (26 Dec) timing-rngs, (27 Dec) stl-inner-product, (28 Dec) stl-transform, (29 Dec) stl-transform-for-subsetting, (30 Dec) stl-random-shuffle, (31 Dec) stl-random-sample, (01 Jan) stl-for-each, (02 Jan) armadillo-subsetting, (03 Jan) accessing-environments, (04 Jan) armadillo-eigenvalues, (05 Jan) r-function-from-c++, (06 Jan) using-the-rcpp-timer, (07 Jan) sugar-function-clamp, (08 Jan) using-rcout, (09 Jan) first-steps-with-C++11, (10 Jan) simple-lambda-func-c++11, (11 Jan) eigen-eigenvalues, (12 Jan) getting-attributes-for-xts-example, (13 Jan) intro-to-exceptions, (14 Jan) a-first-boost-example, (15 Jan) a-second-boost-example, (16 Jan) timing-normal-rngs, (17 Jan) creating-xts-from-c++, (18 Jan) gsl-for-eigenvalues, (19 Jan) accessing-xts-api, (20 Jan) custom-as-and-wrap-example, (21 Jan) passing-cpp-function-pointers,

The Rcpp Gallery continues to grow, we now have 58 posts from 7 different authors. And it is open for business: new contributions are always welcome.

/code/rcpp | permanent link

Fri, 01 Feb 2013

RcppExamples 0.1.6
A pure maintenance release 0.1.6 of RcppExamples was made two weeks ago, and never announced. We merely moved the NEWS.Rd file into the proper location in the inst/ directory, and, while were at it, mentioned the new Rcpp Gallery in the DESCRIPTION file.

Thanks to CRANberries, there is the standard diff to the previous release 0.1.5. Questions, comments etc should go to the rcpp-devel mailing list off the R-Forge page.

/code/rcpp | permanent link

Wed, 30 Jan 2013

RcppArmadillo 0.3.6.2
A new Armadillo version 3.6.2 came out yesterday, and the corresponding RcppArmadillo version is now on CRAN. Changes are mostky incremental:

Changes in RcppArmadillo version 0.3.6.2 (2013-01-29)

  • Upgraded to Armadillo release Version 3.6.2

    • faster determinant for matrices marked as diagonal or triangular

    • more fine-grained handling of 64 bit integers

  • Added a new example of a Kalman filter implementation in R, and C++ using Armadillo via RcppArmadillo, complete with timing comparison

Courtesy of CRANberries, there is also a diffstat report for the most recent release As always, more detailed information is on the RcppArmadillo page. Questions, comments etc should go to the rcpp-devel mailing list off the R-Forge page.

/code/rcpp | permanent link

Wed, 23 Jan 2013

Rcpp reaches 100 dependents on CRAN
With the arrival earlier today of the stochvol package onto the CRAN network for R, our Rcpp project reached a new milestone: 100 packages have either a Depends:, Imports: or LinkingTo: statement on it.

The full list will always be at the bottom of the CRAN page for Rcpp; I also manually edit a list on my Rcpp page. But for the record as of today, here is the current list as produced by a little helper script I keep:

 acer                apcluster           auteur             
 bcp                 bfa                 bfp                
 bifactorial         blockcluster        ccaPP              
 cda                 classify            clusteval          
 ConConPiWiFun       EpiContactTrace     fastGHQuad         
 fdaMixed            forecast            fugeR              
 GeneticTools        gMWT                gof                
 gRbase              gRim                growcurves         
 GUTS                jaatha              KernSmoothIRT      
 LaF                 maxent              mets               
 minqa               mirt                mRMRe              
 multmod             mvabund             MVB                
 NetworkAnalysis     ngspatial           oem                
 openair             orQA                parser             
 pbdBASE             pbdDMAT             phom               
 phylobase           planar              psgp               
 quadrupen           Rchemcpp            Rclusterpp         
 RcppArmadillo       RcppBDT             rcppbugs           
 RcppClassic         RcppClassicExamples RcppCNPy           
 RcppDE              RcppEigen           RcppExamples       
 RcppGSL             RcppOctave          RcppRoll           
 RcppSMC             RcppXts             rforensicbatwing   
 rgam                RInside             Rmalschains        
 Rmixmod             robustgam           robustHD           
 rococo              RProtoBuf           RQuantLib          
 RSNNS               RSofia              rugarch            
 RVowpalWabbit       SBSA                sdcMicro           
 sdcTable            simFrame            spacodiR           
 sparseHessianFD     sparseLTSEigen      SpatialTools       
 stochvol            surveillance        survSNP            
 termstrc            tmg                 transmission       
 trustOptim          unmarked            VIM                
 waffect             WideLM              wordcloud          
 zic                

And not to be forgotten is BioConductor which has another 10:

 ddgraph            GeneNetworkBuilder GOSemSim          
 GRENITS            mosaics            mzR               
 pcaMethods         Rdisop             Risa              
 rTANDEM  

As developers of Rcpp, we are both proud and also a little humbled. The packages using Rcpp span everything from bringing new libraries to R, to implementing faster ways of doing things we have before to doing completely new things. It is an exciting time to be using R, and to be connecting R to C++, especially with so many exciting things happening in C++ right now. Follow the Rcpp links for more, and come join us on the Rcpp-devel mailing list to discuss and learn.

/code/rcpp | permanent link

Tue, 08 Jan 2013

Annoucing the Rcpp Gallery
Earlier this morning, JJ announced what we had been working on for the last few weeks: the Rcpp Gallery.

Now, as our luck will have it, the Rcpp-devel list received his message but did not transmit it for an apparent mail system outage at WU Vienna: no sign at the Gmane archive of rcpp-devel or in the personal mailboxen of myself or anybody I spoke to. Hence, so far, and preceding this blog announcement, the only way word got out was via this earlier tweet of mine from about 12 hours ago.

The Rcpp Gallery is really the brainchild of JJ. It builds on what he contributed over the last few months in not one but two implementations: Rcpp Attributes. These are described in a vignette of their own. They provide very powerful new functions like sourceCpp which allow the easiest-yet way to get compiled code into R---see for example these posts from my blog about simulating pi in essentially five lines of R or five lines of C++, or this post about using the GSL with ease from R. The Rcpp Gallery also builds on Yihui's excellent knitr package which gained the ability to process C++ code just like R code, as well as some Ruby / Jekyll magic to build a website on the github infrastructure. I helped a little on the side by (at long last) learning how to do prettier websites thanks to Boostrap and its theming extensions.

So what does it do, and what is it for? Have a look around the Rcpp Gallery site. Each post is based on a single C++ (or Markdown) file which gets digested by knitr and Rcpp, with the actual output shown alongside the marked up code and explanatory text. Raw sources are available, just pass them into the sourceCpp() function from a current Rcpp release and you should have the same output.

Our idea is to have this as a repository for useful code: from simple and introductory to fancy and featureful. We already seeded it with several dozen posts covered anything from lesser known but powerful STL idioms, to Rcpp sugar, to tieing in Armadillo or GSL, random number generation and of course benchmarking---as we do love performance.

The entire content is in this github repository, and our page on how to contribute details how you can get involved.

We are looking forward to what is to come. In many ways, we are only just getting started.

/code/rcpp | permanent link

Sun, 30 Dec 2012

RcppClassicExamples 0.1.1
Yesterday's initial upload of RcppClassicExamples was lacking a versioned Depends: to prevent builds on older versions of R. This has been added in a new upload 0.1.1. We also added a NEWS file (see below); no code changes were made.

Changes in version 0.1.1 (2012-12-30)

  • Added versioned Depends: in DESCRIPTION to not build under older versions of Rcpp and RcppClassic

Changes in version 0.1.0 (2012-12-27)

Thanks to CRANberries, you can also look at a diff to the previous release 0.1.0. Questions, comments etc should go to the rcpp-devel mailing list off the R-Forge page.

/code/rcpp | permanent link

Sat, 29 Dec 2012

RcppExamples 0.1.5 and RcppClassicExamples 0.1.0
The recent releases of Rcpp 0.10.2 and RcppClassic 0.9.3 had one more repercussion. On that dreaded OS, the linker no longer wanted to instantiate a symbol present in both packages; seems to me that the linker in the other two OSs is a little smarter. Anyway -- I didn't fight this but at long last moved all remnands of the long-deprecated older Rcpp API (which is still maintained by package RcppClassic) out of package RcppExamples and into a new package RcppClassicExamples.

And the updated version 0.1.5 of the RcppExamples package appeared on CRAN and has now been joined by the initial version 0.1.0 of the new package RcppClassicExamples. No code changed were made; manual pages and descriptions where brushed up and that is about it.

Thanks to CRANberries, you can also look at a diff to the previous release 0.1.4 of RcppExamples. Questions, comments etc should go to the rcpp-devel mailing list off the R-Forge page.

/code/rcpp | permanent link

Sat, 22 Dec 2012

RcppClassic 0.9.3
Yesterday's release of Rcpp 0.10.2 required a small change to RcppClassic, the package supporting the deprecated older classic Rcpp API defined in the earlier 2005 to 2006 releases. So version 0.9.3 of RcppClassic is now on CRAN. There is no new user-facing code.

Courtesy of CRANberries, there is the set of changes relative to the previous release 0.9.2.

Questions, comments etc should go to the rcpp-devel mailing list off the R-Forge page.

/code/rcpp | permanent link

Fri, 21 Dec 2012

Rcpp 0.10.2
Relase 0.10.2 of Rcpp provides the second update to the 0.10.* series, and has arrived on CRAN and in Debian.

It brings another great set of enhancements and extensions, building on the recent 0.10.0 and 0.10.1 releases. The new Rcpp attributes were rewritten to not require Rcpp modules (as we encountered on issue with exceptions on Windows when built this way), code was reorganized to significantly accelerate compilation and a couple of new things such as more Rcpp sugar goodies, a new timer class, and a new string class were added. See below for full details.

We also tested this fairly rigorously by checking about two thirds of the over 90 CRAN packages depending on Rcpp (and the remainder required even more package installs which we did not do as this was already taking about 12 total cpu hours to test). We are quite confident that no changes are required (besides one in our own RcppClassic package which we will update.

The complete NEWS entry for 0.10.2 is below; more details are in the ChangeLog file in the package and on the Rcpp Changelog page.

Changes in Rcpp version 0.10.2 (2012-12-21)

  • Changes in Rcpp API:

    • Source and header files were reorganized and consolidated so that compile time are now significantly lower

    • Added additional check in Rstreambuf deletetion

    • Added support for clang++ when using libc++, and for anc icpc in std=c++11 mode, thanks to a patch by Yan Zhou

    • New class Rcpp::String to facilitate working with a single element of a character vector

    • New utility class sugar::IndexHash inspired from Simon Urbanek's fastmatch package

    • Implementation of the equality operator between two Rcomplex

    • RNGScope now has an internal counter that enables it to be safely used multiple times in the same stack frame.

    • New class Rcpp::Timer for benchmarking

  • Changes in Rcpp sugar:

    • More efficient version of match based on IndexHash

    • More efficient version of unique base on IndexHash

    • More efficient version of in base on IndexHash

    • More efficient version of duplicated base on IndexHash

    • More efficient version of self_match base on IndexHash

    • New function collapse that implements paste(., collapse= "" )

  • Changes in Rcpp attributes:

    • Use code generation rather than modules to implement sourceCpp and compileAttributes (eliminates problem with exceptions not being able to cross shared library boundaries on Windows)

    • Exported functions now automatically establish an RNGScope

    • Functions exported by sourceCpp now directly reference the external function pointer rather than rely on dynlib lookup

    • On Windows, Rtools is automatically added to the PATH during sourceCpp compilations

    • Diagnostics are printed to the console if sourceCpp fails and C++ development tools are not installed

    • A warning is printed if when compileAttributes detects Rcpp::depends attributes in source files that are not matched by Depends/LinkingTo entries in the package DESCRIPTION

Thanks to CRANberries, you can also look at a diff to the previous release 0.10.1. As always, even fuller details are on the Rcpp Changelog page and the Rcpp page which also leads to the downloads, the browseable doxygen docs and zip files of doxygen output for the standard formats. A local directory has source and documentation too. Questions, comments etc should go to the rcpp-devel mailing list off the R-Forge page

/code/rcpp | permanent link

Mon, 17 Dec 2012

RcppArmadillo 0.3.6.1
A first minor bug-fix update by Conrad to the 3.6 series of Armadillo arrived today as version 3.6.1, and we prepared a corresponding version 0.3.6.1 of RcppArmadillo, our wrapper for R and Armadillo. This is now on CRAN, and the changes are summarized below.

Changes in RcppArmadillo version 0.3.6.1 (2012-12-17)

  • Upgraded to Armadillo release Version 3.6.1

    • faster trace()

    • fix for handling sparse matrices by dot()

    • fixes for interactions between sparse and dense matrices

  • Now throws compiler error if Rcpp.h is included before RcppArmadillo.h (as the former is included automatically by the latter anyway, but template logic prefers this ordering).

Courtesy of CRANberries, there is also a diffstat report for the most recent release As always, more detailed information is on the RcppArmadillo page. Questions, comments etc should go to the rcpp-devel mailing list off the R-Forge page.

/code/rcpp | permanent link

Fri, 07 Dec 2012

RcppArmadillo 0.3.6.0
Conrad launched the 3.6 series of Armadillo earlier today with a first 3.6.0 release. So RcppArmadillo, our wrapper for R and Armadillo, is now on CRAN with its corresponding version 0.3.6.0. No R level or interface changes were needed, and the upstream changes are summarized below.

Changes in RcppArmadillo version 0.3.6.0 (2012-12-07)

  • Upgraded to Armadillo release Version 3.6.0 (Piazza del Duomo)

    • faster handling of compound expressions with submatrices and subcubes

    • added support for loading matrices as text files with NaN and Inf elements

    • added stable_sort_index(), which preserves the relative order of elements with equivalent values

    • added handling of sparse matrices by mean(), var(), norm(), abs(), square(), sqrt()

    • added saving and loading of sparse matrices in arma_binary format

Courtesy of CRANberries, there is also a diffstat report for the most recent release As always, more detailed information is on the RcppArmadillo page. Questions, comments etc should go to the rcpp-devel mailing list off the R-Forge page.

/code/rcpp | permanent link

Tue, 27 Nov 2012

Rcpp 0.10.1
A the new Rcpp release 0.10.1 arrived this morning on CRAN (as already has Windows binaries) and in Debian.

This is a follow-up to the recent 0.10.0 release which extends the exciting new Rcpp-attributes and Rcpp-sugar work further, and as in a number of other areas as detailed below in the NEWS sections.

This release brings an change to some of the binary interfaces. If you have packages using Rcpp, you will most likely have to reinstall them from source. Some change were made to const correctness as well as other aspects, and it seems that we have temporarily broken the excellent RcppEigen and RcppOctave packages. We are looking into this, and are sorry about the bug.

The complete NEWS entry for 0.10.1 is below; more details are in the ChangeLog file in the package and on the Rcpp Changelog page.

Changes in Rcpp version 0.10.1 (2012-11-26)

  • Changes in Rcpp sugar:

    • New functions: setdiff, union_, intersect setequal, in, min, max, range, match, table, duplicated

    • New function: clamp which combines pmin and pmax, e.g. clamp( a, x, b) is the same as pmax( b, pmin(x, a) )

    • New function: self_match which implements something similar to match( x, unique( x ) )

  • Changes in Rcpp API:

    • The Vector template class (hence NumericVector ...) get the is_na and the get_na static methods.

    • New helper class no_init that can be used to create a vector without initializing its data, e.g. : IntegerVector out = no_init(n) ;

    • New exception constructor requiring only a message; stop function to throw an exception

    • DataFrame gains a nrows method

  • Changes in Rcpp attributes:

    • Ability to embed R code chunks (via specially formatted block comments) in C++ source files.

    • Allow specification of argument defaults for exported functions.

    • New scheme for more flexible mixing of generated and user composed C++ headers.

    • Print warning if no export attributes are found in source file.

    • Updated vignette with additional documentation on exposing C++ interfaces from packages and signaling errors.

  • Changes in Rcpp modules:

    • Enclose .External invocations in BEGIN_RCPP/END_RCPP

  • Changes in R code :

    • New function areMacrosDefined

    • Additions to Rcpp.package.skeleton:

      • attributes parameter to generate a version of rcpp_hello_world that uses Rcpp::export.

      • cpp_files parameter to provide a list of C++ files to include the in the src directory of the package.

  • Miscellaneous changes:

    • New example 'pi simulation' using R and C++ via Rcpp attributes

Thanks to CRANberries, you can also look at a diff to the previous release 0.10.0. As always, even fuller details are on the Rcpp Changelog page and the Rcpp page which also leads to the downloads, the browseable doxygen docs and zip files of doxygen output for the standard formats. A local directory has source and documentation too. Questions, comments etc should go to the rcpp-devel mailing list off the R-Forge page

/code/rcpp | permanent link

Fri, 16 Nov 2012

RcppArmadillo 0.3.4.4
A minor bug-fix release 3.4.4 of Armadillo came out upstream a few days ago. RcppArmadillo, our wrapper for R and Armadillo, is now on CRAN with its corresponding version 0.3.4.4. No R level or interface changes were made and the upstream changes are summarized below.

Changes in RcppArmadillo version 0.3.4.4 (2012-11-15)

  • Upgraded to Armadillo release 3.4.4

    • fix for handling complex numbers by sparse matrices

    • fix for minor memory leak by sparse matrices

Courtesy of CRANberries, there is also a diffstat report for 0.3.4.4 relative to 0.3.4.3 As always, more detailed information is on the RcppArmadillo page. Questions, comments etc should go to the rcpp-devel mailing list off the R-Forge page.

/code/rcpp | permanent link

Wed, 14 Nov 2012

Rcpp 0.10.0
Rcpp release 0.10.0 is now on CRAN and being uploaded to Debian.

This is a new feature release, and we are very exciting about the changes, notably Rcpp attributes which make using C++ from R even easier than inline (see below as well as the new vignette for details and first examples), the extensions to Rcpp modules (see below) and more as for example new Rcpp sugar functions, a new error output device syncing to R, and a new namespace R> for the statistical functions from Rmath.h.

The complete NEWS entry for 0.10.0 is below; more details are in the ChangeLog file in the package and on the Rcpp Changelog page.

Changes in Rcpp version 0.10.0 (2012-11-13)

  • Support for C++11 style attributes (embedded in comments) to enable use of C++ within interactive sessions and to automatically generate module declarations for packages:

    • Rcpp::export attribute to export a C++ function to R

    • sourceCpp() function to source exported functions from a file

    • cppFunction() and evalCpp() functions for inline declarations and execution

    • compileAttribtes() function to generate Rcpp modules from exported functions within a package

    • Rcpp::depends attribute for specifying additional build dependencies for sourceCpp()

    • Rcpp::interfaces attribute to specify the external bindings compileAttributes() should generate (defaults to R-only but a C++ include file using R_GetCCallable can also be generated)

    • New vignette "Rcpp-attribute"

  • Rcpp modules feature set has been expanded:

    • Functions and methods can now return objects from classes that are exposed through modules. This uses the make_new_object template internally. This feature requires that some class traits are declared to indicate Rcpp's wrap/as system that these classes are covered by modules. The macro RCPP_EXPOSED_CLASS and RCPP_EXPOSED_CLASS_NODECL can be used to declared these type traits.

    • Classes exposed through modules can also be used as parameters of exposed functions or methods.

    • Exposed classes can declare factories with ".factory". A factory is a c++ function that returns a pointer to the target class. It is assumed that these objects are allocated with new on the factory. On the R side, factories are called just like other constructors, with the "new" function. This feature allows an alternative way to construct objects.

    • "converter" can be used to declare a way to convert an object of a type to another type. This gets translated to the appropriate "as" method on the R side.

    • Inheritance. A class can now declare that it inherits from another class with the .derives<Parent>( "Parent" ) notation. As a result the exposed class gains methods and properties (fields) from its parent class.

  • New sugar functions:

    • which_min implements which.min. Traversing the sugar expression and returning the index of the first time the minimum value is found.

    • which_max idem

    • unique uses unordered_set to find unique values. In particular, the version for CharacterVector is found to be more efficient than R's version

    • sort_unique calculates unique values and then sorts them.

  • Improvements to output facilities:

    • Implemented sync() so that flushing output streams works

    • Added Rcerr output stream (forwarding to REprintf)

  • Provide a namespace 'R' for the standalone Rmath library so that Rcpp users can access those functions too; also added unit tests

  • Development releases sets variable RunAllRcppTests to yes to run all tests (unless it was alredy set to 'no'); CRAN releases do not and still require setting – which helps with the desired CRAN default of less testing at the CRAN server farm.

Thanks to CRANberries, you can also look at a diff to the previous release 0.9.15. As always, even fuller details are on the Rcpp Changelog page and the Rcpp page which also leads to the downloads, the browseable doxygen docs and zip files of doxygen output for the standard formats. A local directory has source and documentation too. Questions, comments etc should go to the rcpp-devel mailing list off the R-Forge page

Update: One link corrected.

/code/rcpp | permanent link

Sun, 14 Oct 2012

Rcpp 0.9.15
Rcpp release 0.9.15 is now on CRAN and being uploaded to Debian.

Martin Morgan provided a clever fix for a header search needed between clang++ (especially on OS X) and g++ (which still provided libstdc++ and headers for clang++). This should hopefully put the clang issues to bed. Ben North noticed an unprotected string conversion when exception messages are turned into R errors which got fixed, and I expanded the coverage of Date (and Datetime) types to deal properly with non-finite values NA, NaN and Inf.

The complete NEWS entry for 0.9.15 is below; more details are in the ChangeLog file in the package and on the Rcpp Changelog page.

Changes in Rcpp version 0.9.15 (2012-10-13)

  • Untangling the clang++ build issue about the location of the exceptions header by directly checking for the include file – an approach provided by Martin Morgan in a kindly contributed patch as unit tests for them.

  • The Date and Datetime types now correctly handles NA, NaN and Inf representation; the Date type switched to an internal representation via double

  • Added Date and Datetime unit tests for the new features

  • An additional PROTECT was added for parsing exception messages before returning them to R, following a report by Ben North

Thanks to CRANberries, you can also look at a diff to the previous release 0.9.14. As always, even fuller details are on the Rcpp Changelog page and the Rcpp page which also leads to the downloads, the browseable doxygen docs and zip files of doxygen output for the standard formats. A local directory has source and documentation too. Questions, comments etc should go to the rcpp-devel mailing list off the R-Forge page

/code/rcpp | permanent link

Thu, 04 Oct 2012

RcppArmadillo 0.3.4.3
Another bug-fix release of Armadillo, now at version 3.4.3 whike the 3.4.* stabilizes, and with it a version 0.3.4.3 of RcppArmadillo, our wrapper for R and Armadillo. The new version is already on CRAN as of earlier today. Once again no R level or interface changes were, the upstream changes are summarized below.

Changes in RcppArmadillo version 0.3.4.3 (2012-10-04)

  • Upgraded to Armadillo release 3.4.3

    • fix for aliasing issue in diagmat()

    • fix for speye() signature

Courtesy of CRANberries, there is also a diffstat report for 0.3.4.3 relative to 0.3.4.2 As always, more detailed information is on the RcppArmadillo page. Questions, comments etc should go to the rcpp-devel mailing list off the R-Forge page.

/code/rcpp | permanent link

Mon, 01 Oct 2012

Rcpp 0.9.14
Another release of Rcpp has just appeared on CRAN and was just uploaded to Debian.

It addresses yet another issue we had on OS X and should hopefully put the build issues to rest. Three new (vectorized) sugar functions were added, along with some new regression tests and more. The complete NEWS entry for 0.9.14 is below; more details are in the ChangeLog file in the package and on the Rcpp Changelog page.

Changes in Rcpp version 0.9.14 (2012-09-30)

  • Added new Rcpp sugar functions trunc(), round() and signif(), as well as unit tests for them

  • Be more conservative about where we support clang++ and the inclusion of exception_defines.h and prevent this from being attempted on OS X where it failed for clang 3.1

  • Corrected a typo in Module.h which now again permits use of finalizers

  • Small correction for (unexported) bib() function (which provides a path to the bibtex file that ships with Rcpp)

  • Converted NEWS to NEWS.Rd

Thanks to CRANberries, you can also look at a diff to the previous release 0.9.13. As always, even fuller details are on the Rcpp Changelog page and the Rcpp page which also leads to the downloads, the browseable doxygen docs and zip files of doxygen output for the standard formats. A local directory has source and documentation too. Questions, comments etc should go to the rcpp-devel mailing list off the R-Forge page

/code/rcpp | permanent link

Tue, 25 Sep 2012

RcppArmadillo 0.3.4.2
The development of Armadillo 3.4.* continues with bug fixes and more sparse matrix support. Conrad release 3.4.2 this morning. I wrapped up the corresponding RcppArmadillo 0.3.4.2 before leaving for work, and this version should now have all CRAN mirrors. Once again no R level or interface changes were, the upstream changes are summarized below.

Changes in RcppArmadillo version 0.3.4.2 (2012-09-25)

  • Upgraded to Armadillo release 3.4.2

    • minor fixes for handling sparse submatrix views

    • minor speedups for sparse matrices

Courtesy of CRANberries, there is also a diffstat report for 0.3.4.2 relative to 0.3.4.1 As always, more detailed information is on the RcppArmadillo page. Questions, comments etc should go to the rcpp-devel mailing list off the R-Forge page.

/code/rcpp | permanent link

Tue, 18 Sep 2012

RcppArmadillo 0.3.4.1
Conrad released the bug-fix release 3.4.1 of Armadillo earlier today, and the corresponding RcppArmadillo package 0.3.4.1 is already on CRAN. No R level or interface changes were, the upstream changes are summarized below.

Changes in RcppArmadillo version 0.3.4.1 (2012-09-18)

  • Upgraded to Armadillo release 3.4.1

    • workaround for a bug in the Mac OS X accelerate framework

    • fixes for handling empty sparse matrices

    • added documentation for saving & loading matrices in HDF5 format

    • faster dot() and cdot() for complex numbers

Courtesy of CRANberries, there is also a diffstat report for 0.3.4.1 relative to 0.3.4.0 As always, more detailed information is on the RcppArmadillo page. Questions, comments etc should go to the rcpp-devel mailing list off the R-Forge page.

/code/rcpp | permanent link

Thu, 06 Sep 2012

RcppArmadillo 0.3.4.0
A new major released of Armadillo came out earlier today. I prepared the corresponding RcppArmadillo package 0.3.4.0 which also arrived on CRAN earlier today. This released contains a few performance improvements, the beginnings of support of sparse matrices and more, see below. We also post the NEWS entry for the beta release which was prepared, but not uploaded to CRAN to minimise the upload frequency there. On the RcppArmadillo side, two enhancements were made for the fastLm() function for faster linear model fits.

Changes in RcppArmadillo version 0.3.4.0 (2012-09-06)

  • Upgraded to Armadillo release 3.4.0 (Ku De Ta)

    • added economical QR decomposition: qr_econ()

    • added .each_col() & .each_row() for vector operations repeated on each column or row

    • added preliminary support for sparse matrices, contributed by Ryan Curtin et al. (Georgia Institute of Technology)

    • faster singular value decomposition via divide-and-conquer algorithm

    • faster .randn()

  • NEWS file converted to Rd format

Changes in RcppArmadillo version 0.3.3.91 (2012-08-30)

  • Upgraded to Armadillo release 3.3.91

    • faster singular value decomposition via "divide and conquer" algorithm

    • added economical QR decomposition: qr_econ()

    • added .each_col() & .each_row() for vector operations repeated on each column or row

    • added preliminary support for sparse matrices, contributed by Ryan Curtin, James Cline and Matthew Amidon (Georgia Institute of Technology)

  • Corrected summary method to deal with the no intercept case when using a formula; also display residual summary() statistics

  • Expanded unit tests for fastLm

Courtesy of CRANberries, there is also a diffstat report for 0.3.4.0 relative to 0.3.2.4 As always, more detailed information is on the RcppArmadillo page. Questions, comments etc should go to the rcpp-devel mailing list off the R-Forge page.

/code/rcpp | permanent link

Fri, 10 Aug 2012

RcppExamples 0.1.4
An updated version 0.1.4 of the RcppExamples package is now on on CRAN. RcppExamples contains a few illustrations of how to use Rcpp.

The NEWS entry is below: a new example was added illustrating use of the (vectorised) random-number generators for three of the different distributions --- and showing how it perfectly reproduces the values one gets in R.

Changes in RcppExamples version 0.1.4 (2012-08-09)

  • Added new example for Rcpp sugar and vectorised draws of RNGs

  • Minor updates to reflect newer CRAN Policy

Thanks to CRANberries, you can also look at a diff to the previous release 0.1.3. Questions, comments etc should go to the rcpp-devel mailing list off the R-Forge page

/code/rcpp | permanent link

Wed, 08 Aug 2012

RcppBDT 0.2.1
A new bug-fix release of the RcppBDT package appeared on CRAN earlier today. David Reiner noticed that the functions getEndOfMonth and getEndOfBizWeek were not working right. These are convenience wrappers around the real functionality provided as a member function to the reference class built by Rcpp modules---which works off a reference instance of the class, and these two convenience functions were not updating the date. This is now fixed.

The complete NEWS entry is below:

Changes in version 0.2.1 (2012-08-08)

  • Bug for getEndOfBizWeek() and getEndOfMonth() who were lacking a call to fromDate(date) to actually pass the date for which the functions are computing the end of business week or month.

Courtesy of CRANberries, there is also a diffstat report for 0.2.1 relative to 0.2.0. As always, feedback is welcome and the rcpp-devel mailing list off the R-Forge page for Rcpp is the best place to start a discussion.

/code/rcpp | permanent link

Tue, 31 Jul 2012

RcppCNPy 0.2.0
Version 0.2.0 of the recently introduced RcppCNPy package for reading/writing NumPy data in R arrived on CRAN earlier today.

The main change are the added ability to also write gzip-ed npy files, to suppress an automatic transposition as well as the correction of one memory leak on data read.

The NEWS file entry is below:

Changes in version 0.2.0 (2012-07-30)

  • Support for writing of gzip-ed npy files has been added.

  • A new option dotranspose has been added to npyLoad() to support data sets that do not need to be transposed to be used in R.

  • A memory leak in reading files has been corrected.

CRANberries also provides a diffstat report for 0.2.0 relative to 0.1.0. As always, feedback is welcome and the rcpp-devel mailing list off the R-Forge page for Rcpp is the best place to start a discussion.

/code/rcpp | permanent link

Tue, 24 Jul 2012

RcppClassic 0.9.2
Similar to yesterday's post about RcppGSL, we have another pure maintenance release to announce, this time of RcppClassic, the package supporting the deprecated older classic Rcpp API defined in the earlier 2005 to 2006 releases, is now on CRAN. There is no new code, as the only changes were made to accomodate CRAN Policy updates.

Courtesy of CRANberries, here is a link to the changes relative to the previous release 0.9.1.

Questions, comments etc should go to the rcpp-devel mailing list off the R-Forge page.

/code/rcpp | permanent link

Mon, 23 Jul 2012

RcppGSL 0.2.0
Earlier today, a minor update / maintenance release of RcppGSL---our interface package between R and the GNU GSL using our Rcpp package for seamless R and C++ integration---arrived on on CRAN. It contains a number of minor changes to accomodate changes in the CRAN Policies, as well as a few extension to the main example fastLm, a faster replacement for the standard lm function. The summary methods now provide more information, and we added a number of new regression tests.

The NEWS file entry follows below:

Changes in version 0.2.0 (2012-07-22)
  • summary() for fastLm() now displays more information

  • fastLmPure() now uses same argument order as R's lm.fit()

  • Added more unit tests for fastLm() and related functions

  • Export and document S3 methods in NAMESPACE and manual page as such

  • Vignettes have been moved to the vignettes/ directory

  • Main vignette renamed to RcppGSL-intro.pdf to use a filename different from the package reference manual

  • NEWS file converted to .Rd format

  • inline support function no longer uses assignInNamespace

And courtesy of CRANberries, a summary of the changes to the previous release 0.1.1 is available too.

More information is on the RcppGSL page. Questions, comments etc should go to the rcpp-devel mailing list off the R-Forge page.

/code/rcpp | permanent link

Thu, 12 Jul 2012

RcppArmadillo 0.3.2.4
Conrad released version 3.2.4 of Armadillo yesterday. It contains a workaround for g++ 4.7.0 and 4.7.1 which have a regression triggered by the Armadillo codebase for small fixed-sized matrices. The corresponding RcppArmadillo package 0.3.2.4 arrived on CRAN earlier today.

The short NEWS entry follows below.

0.3.2.4  2012-07-11

    o   Upgraded to Armadillo release 3.2.4

          * workaround for a regression (bug) in GCC 4.7.0 and 4.7.1

Courtesy of CRANberries, there is also a diffstat report for 0.3.2.4 relative to 0.3.2.3 As always, more detailed information is on the RcppArmadillo page. Questions, comments etc should go to the rcpp-devel mailing list off the R-Forge page.

/code/rcpp | permanent link

Sun, 08 Jul 2012

New package RcppCNPy with release 0.1.0 (and 0.0.1 earlier last week)
A few days ago I had blogged about getting NumPy data in R by using a simple converter script. That works fine, but it is a little annoying to have to write an entire file only to read from it again. So I kept looking around for a better solution---and soon found the cnpy library by Carl Rogers which provides simple C++ functions to read and write NumPy files.

Bringing such a C++ library to R is done very easily via Rcpp modules. The resulting package contains a single R file with a single line: loadModule("cnpy", TRUE). And it relies on the following module declarations in the a C++ file:

RCPP_MODULE(cnpy){

    using namespace Rcpp;

    function("npyLoad",                         // name of the identifier at the R level
             &npyLoad,                          // function pointer to helper function defined above
             List::create( Named("filename"),   // function arguments including default value
                           Named("type") = "numeric"),
             "read an npy file into a numeric or integer vector or matrix");

    function("npySave",                         // name of the identifier at the R level
             &npySave,                          // function pointer to helper function defined above
             List::create( Named("filename"),   // function arguments including default value
                           Named("object"), 
                           Named("mode") = "w"),
             "save an R object (vector or matrix of type integer or numeric) to an npy file");

}
which give us at the R prompt
R> library(RcppCNPy)
Loading required package: Rcpp
R> npyLoad
internal C++ function <0x243af70>
    docstring : read an npy file into a numeric or integer vector or matrix
    signature : Rcpp::RObject npyLoad(std::string, std::string)
R> npySave
internal C++ function <0x23033e0>
    docstring : save an R object (vector or matrix of type integer or numeric) to an npy file
    signature : void npySave(std::string, Rcpp::RObject, std::string)
R> 
these two functions (and their docstrings) defined above. That's all! Well there are about one hundred more lines dealing with whether we have integer or numeric data, and whether we use a vector or a matrix. But all in all pretty simple...

So version 0.1.0 of this new package RcppCNPy completes the initial release 0.0.1 from earlier in the week by adding

  • the ability to load compressing NumPy files ending in .npy.gz
  • a simple regression test suite loading some data sets
  • a demo script with a timing example comparing ascii reads to reading npy and compressed npy
  • a short pdf vignette describing the package

The NEWS entry for this release (as well as the initial one) follow:

News for Package RcppCNPy

Changes in version 0.1.0 (2012-07-07)
  • Added automatic use of transpose to automagically account for Fortran-vs-C major storage defaults between Python and R.

  • Support for integer types in dependent on the int64_t type which is available only when the -std=c++0x switch is used at build-time (and CRAN still discourages use of it)

  • Added support for reading gzip'ed files ending in ".npy.gz"

  • Added regression tests in directory tests/

  • Added a vignette describing the package

  • Added a timing benchmark in demo/timings.R

Changes in version 0.0.1 (2012-07-04)
  • Initial version, as a straightforward Rcpp modules wrap around the cpny library by Carl Rogers (on github under a MIT license).

  • At present, npy files can be read and written for vectors and matrices of either numeric or integer type. Note however that matrices are currently transposed because of the default Fortran ordering done by numpy.

I will follow up with a little usage example later.

CRANberries also provides a diffstat report for 0.1.0 relative to 0.0.1. As always, feedback is welcome and the rcpp-devel mailing list off the R-Forge page for Rcpp is the best place to start a discussion.

/code/rcpp | permanent link

Tue, 03 Jul 2012

RcppBDT 0.2.0
A new release of the RcppBDT package appeared on CRAN earlier today.

RcppBDT uses Rcpp, and in particular the nifty Rcpp modules feature of wrapping C++ code for R just by declaring the (class or function) interfaces. It uses this to bring in some useful functions from Boost Date.Time to R so that one can do things like

R> library(RcppBDT)
R> sapply(2012:2016, function(year)
+         format(getNthDayOfWeek(first, Mon, Sep, year)))
[1] "2012-09-03" "2013-09-02" "2014-09-01" "2015-09-07" "2016-09-05"
R> 
to compute the next five Labor Day dates in the US, given the year and the first Monday of September requirement. More examples are e.g. on the earlier blog post announcing version 0.1.0.

Changes are mostly internal. R 2.15.1 brough a better / easier way to load such 'modules' into R, and Rcpp 0.9.13 allows us to use this. So RcppBDT continues to be useful as an example package for Rcpp modules. I also streamlines the interface a little: identifiers are now directly accessible in the package's NAMESPACE rather than just via the an instantiated object.

I also added a NEWS file, using the .Rd format so that we can import the marked-up text:

News for Package RcppBDT

Changes in version 0.2.0 (2012-07-02)
  • The core module, which wraps what in C++ is boost::gregorian::date, is now exposed as an Rcpp module bdtDate. As all example and demos operated off a (package-global) variable 'bdt', no user visible change was needed outside of the code instantiating at package load.

  • Updated package instantiation to the new facilities offered by the current versions R 2.15.1 and Rcpp 0.9.13 which make Rcpp module initialization easier and more streamlined.

Changes in version 0.1.0 (2011-01-17)
  • First CRAN upload (and see ChangeLog for more granular details) bug fix in svm cross validation

Courtesy of CRANberries, there is also a diffstat report for 0.2.0 relative to 0.1.0. As always, feedback is welcome and the rcpp-devel mailing list off the R-Forge page for Rcpp is the best place to start a discussion.

/code/rcpp | permanent link

Mon, 02 Jul 2012

RcppArmadillo 0.3.2.3
Conrad releaser version 3.2.3 of Armadillo a few days ago, and the corresponding RcppArmadillo package 0.3.2.3 is now CRAN. (For these keeping score 3.2.1 never was a full release, and 3.2.2 containing fixes for a build issue that did not affect the R package build so we skipped it.)

The short NEWS entry follows below. This version fixes some issues related to g++ 4.7; however the current Debian testing version of g++-4.7.1 required that I rolled back three header files to the version from the previous release. Conrad has been in contact with the gcc upstream maintainers and a fix may appear in time for g++-4.7.2.

This release also contains a new introductory pdf vignette based on a paper Conrad and I just submitted. It introduces Armadillo to R programmers and demonstrates with a simple Kalman filtering example how the code can be written in the same concise matrix-oriented style, yet runs orders of magnitude faster.

0.3.2.3  2012-07-01

    o   Upgraded to Armadillo release 3.2.3 

          * minor correction for declaration of fixed size vectors and
            matrices

    o   Reverted three header files {Mat,Row,Col}_bones.hpp back to previous
        release due to compilation failures under g++-4.7

    o   Added new vignette 'RcppArmadillo-intro' based on a just-submitted
        introductory paper (by Eddelbuettel and Sanderson) about RcppArmadillo 

    o   Change from release 3.2.2 which we skipped as it did not really affect
        builds under R:

          * minor fix for compiling without debugging enabled (aka release
            mode)
          * better detection of ATLAS during installation on Fedora and Red
            Hat systems

    o   Small enhancement to fastLm 

Courtesy of CRANberries, there is also a diffstat report for 0.3.2.3 relative to 0.3.2.0 As always, more detailed information is on the RcppArmadillo page. Questions, comments etc should go to the rcpp-devel mailing list off the R-Forge page.

/code/rcpp | permanent link

Fri, 29 Jun 2012

Rcpp 0.9.13
The bug-fix in version 0.9.12 of Rcpp turned out to be incomplete, so a new version 0.9.13 is now on CRAN and will get to Debian shortly.

The Rcpp::Enviroment constructor is now properly fixed (using the global environment as a default value). As well, a new #define was created to detect the clang++ compiler before/after version 3.0.0 as one exceptions header changed location. Unit tests files were also once more updated.

The complete NEWS entry for 0.9.13 is below; more details are in the ChangeLog file in the package and on the Rcpp Changelog page.

0.9.13  2012-06-28

    o   Truly corrected Rcpp::Environment class by having default constructor
        use the global environment, and removing the default argument of
        global environment from the SEXP constructor

    o   Added tests for clang++ version to include bits/exception_defines.h
        for versions 3.0 or higher (similar to g++ 4.6.0 or later), needed to
        include one particular exceptions header

    o   Made more regression tests conditional on the RunAllRcppTests to come
        closer to the CRAN mandate of running tests in sixty seconds

    o   Updated unit test wrapper tests/doRUnit.R as well as unitTests/runTests.R

Thanks to CRANberries, you can also look at a diff to the previous release 0.9.12. As always, even fuller details are on the Rcpp Changelog page and the Rcpp page which also leads to the downloads, the browseable doxygen docs and zip files of doxygen output for the standard formats. A local directory has source and documentation too. Questions, comments etc should go to the rcpp-devel mailing list off the R-Forge page

/code/rcpp | permanent link

Mon, 25 Jun 2012

Rcpp 0.9.12
A bug-fix release 0.9.12 of Rcpp arrived earlier today on CRAN and is now in Debian too.

This fixes a minor snafu with the Rcpp::Enviroment constructor following a small change made for 0.9.11. It also reduces the number of unit tests running by default as CRAN was complaining that it took too long to run the checks. I am not impressed---tests are for running, not skipping. Lastly, the cleanup needed to be extended to another directory.

The complete NEWS entry for 0.9.12 is below; more details are in the ChangeLog file in the package and on the Rcpp Changelog page.

0.9.12  2012-06-23

    o   Corrected Rcpp::Environment class by removing (empty) ctor following
        rev3592 (on May 2) where default argument for ctor was moved

    o   Unit testing now supports argument --allTests to impose that all
        tests are executed; otherwise some expensive tests are skipped. This
        is arguably not the right thing to do, but CRAN maintainers insist 
        on faster tests.

    o   The cleanup script now also considers inst/unitTests/testRcppClass/src 

Thanks to CRANberries, you can also look at a diff to the previous release 0.9.11. As always, even fuller details are on the Rcpp Changelog page and the Rcpp page which also leads to the downloads, the browseable doxygen docs and zip files of doxygen output for the standard formats. A local directory has source and documentation too. Questions, comments etc should go to the rcpp-devel mailing list off the R-Forge page

/code/rcpp | permanent link

Fri, 22 Jun 2012

Rcpp 0.9.11
Release 0.9.11 of Rcpp arrived on CRAN this morning and in Debian later today.

This is a somewhat incremental release with a few internal improvements and few new features. One interesting new development has been contributed by John Chambers who is extending 'Rcpp modules' into 'Rcpp classes' which allows R code to modify and extend C++ classes loaded via Rcpp modules; see help(setRcppClass) for more. This also lead to some changes in the code for loading modules which however requires the brand-new R version 2.15.1 released today as well.

The complete NEWS entry for 0.9.11 is below; more details are in the ChangeLog file in the package and on the Rcpp Changelog page.

0.9.11  2012-06-22

    o   New member function for vectors (and lists etc) containsElementNamed() 
        which returns a boolean indicating if the given element name is present

    o   Updated the Rcpp.package.skeleton() support for Rcpp modules by
        carrying functions already present from the corresponding unit test
        which was also slightly expanded; and added more comments to the code 

    o   Rcpp modules can now be loaded via loadRcppModules() from .onLoad(),
        or via loadModule("moduleName") from any R file 

    o   Extended functionality to let R modify C++ clases imported via modules
        documented in help(setRcppClass)

    o   Support compilation in Cygwin thanks to a patch by Dario Buttari

    o   Extensions to the Rcpp-FAQ and the Rcpp-modules vignettes

    o   The minium version of R is now 2.15.1 which is required for some of
        the Rcpp modules support 

Thanks to CRANberries, you can also look at a diff to the previous release 0.9.10. As always, even fuller details are on the Rcpp Changelog page and the Rcpp page which also leads to the downloads, the browseable doxygen docs and zip files of doxygen output for the standard formats. A local directory has source and documentation too. Questions, comments etc should go to the rcpp-devel mailing list off the R-Forge page

/code/rcpp | permanent link

Mon, 21 May 2012

RcppArmadillo 0.3.2.0
A new stable release 3.2.0 of Armadillo is now available. As usual, we have wrapped this into a new RcppArmadillo package, now at 0.3.0.2; and this version is now available via CRAN.

The short NEWS entry follows below. For those interested in following RcppArmadillo eevn more closely, we generally track Conrad's Armadillo release candidates as well in SVN on R-Forge but do no longer submit these to CRAN (as the CRAN maintainers have enough incoming packages).

0.3.2.0  2012-05-21

    o   Upgraded to Armadillo release 3.2.0 "Creamfields"

          * faster eigen decomposition via "divide and conquer" algorithm
          * faster transpose of vectors and compound expressions
          * faster handling of diagonal views
          * faster handling of tiny fixed size vectors (≤ 4 elements)
          * added unique(), for finding unique elements of a matrix

Courtesy of CRANberries, there is also a diffstat report for 0.3.2.0 relative to 0.3.0.3 As always, more detailed information is on the RcppArmadillo page. Questions, comments etc should go to the rcpp-devel mailing list off the R-Forge page.

/code/rcpp | permanent link

Tue, 15 May 2012

RcppSMC 0.1.1
CRAN now tests packages against g++-4.7 (as this version has become the default on Debian's testing variant. This compiler switch once again triggered a set of build failures, mostly from include files now deemed missing. For RcppSMC, it came down to a five-character patch of explicitly stating one max() call as std::max()

No other changes were made at this point. The NEWS entry is below:

0.1.1   2012-05-14

    o   Version 0.1.1 

    o   Minor g++-4.7 build fix of using std::max() explicitly

Courtesy of CRANberries, there is also a diffstat report for 0.1.1 relative to 0.1.0 As always, more detailed information is on the RcppSMC page,

/code/rcpp | permanent link

Sat, 05 May 2012

RcppArmadillo 0.3.0.3
Two days ago, Conrad Sanderson released another bug-fix version 3.0.3 for the 3.0.0 branch of his excellent Armadillo C++ template library for linear algebra. The new RcppArmadillo release 0.3.0.3 which contains it appeared on CRAN yesterday. Beside Conrad's bugfixes we also added an example script for fastLm and faster linear model fits.

The short NEWS entry follows below.

0.3.0.3 2012-05-03

    o   Upgraded to Armadillo release 3.0.3

          * fixes for inplace transpose of complex number matrices
          * fixes for complex number version of svd_econ()
          * fixes for potential aliasing issues with submatrix views

    o   New example script fastLm 

Courtesy of CRANberries, there is also a diffstat report for 0.3.0.3 relative to 0.3.0.2 As always, more detailed information is on the RcppArmadillo page. Questions, comments etc should go to the rcpp-devel mailing list off the R-Forge page.

/code/rcpp | permanent link

Thu, 19 Apr 2012

RcppArmadillo 0.3.0.2 released and on CRAN
Earlier today, Conrad Sanderson released another bug-fix version 3.0.2 for the still fairly recent 3.0.0 version of his excellent Armadillo C++ template library for linear algebra. The new RcppArmadillo release 0.3.0.2 also appeared on CRAN this morning.

Beside Conrad's bugfix in Armadillo itself, he also convinced us to unroll a change imposed by R: NDEBUG is now being defined unconditionally when compiling R packages. In Armadillo's case, this suppresses a number of useful things including bounds-checking. So we now undefine this symbol in the initial RcppArmadillo headers. Users can still set it manually, and/or define ARMA_NO_DEBUG.

The short NEWS entry follows below.

0.3.0.2 2012-04-19

    o   Upgraded to Armadillo release 3.0.2

          * fixes for handling diagonal matrices

    o   Undefine NDEBUG if it has been set (as R does) as this prevents a
        number of useful debugging checks. Users can still define it or
        define ARMA_NO_DEBUG if they want a 'non-development' build

Courtesy of CRANberries, there is also a diffstat report for 0.3.0.2 relative to 0.3.0.1 As always, more detailed information is on the RcppArmadillo page. Questions, comments etc should go to the rcpp-devel mailing list off the R-Forge page.

/code/rcpp | permanent link

Thu, 12 Apr 2012

RcppArmadillo 0.3.0.1 released and on CRAN
Conrad Sanderson released a bug-fix version 3.0.1 following up on the very recent 3.0.0 version of his excellent Armadillo C++ template library for linear algebra. I made a new RcppArmadillo release 0.3.0.1 which just appeared on CRAN.

The short NEWS entry follows below.

0.3.0.1 2012-04-12

    o   Upgraded to Armadillo release 3.0.1

          * fixes for compilation errors
          * fixes for potential aliasing issues

Courtesy of CRANberries, there is also a diffstat report for 0.3.0.1 relative to 0.3.0 As always, more detailed information is on the RcppArmadillo page. Questions, comments etc should go to the rcpp-devel mailing list off the R-Forge page.

/code/rcpp | permanent link

Wed, 11 Apr 2012

RcppArmadillo 0.3.0 is now on CRAN
Conrad Sanderson has released a new major version 3.0.0 of his excellent Armadillo C++ template library for linear algebra. A corresponding new release 0.3.0 of RcppArmadillo is now on CRAN. This follows four pre-releases of Armadillo which we packaged as before, but for reasons detailed in another post did not send to CRAN.

All that said, here are the NEWS entries for all release since the last non-test release:

0.3.0   2012-04-10

    o   Upgraded to Armadillo release 3.0.0 "Antarctic Chilli Ranch"

          * added non-contiguous submatrix views
          * added shorthand for inverse: .i()
          * added hist() and histc()
          * faster repmat()
          * faster handling of submatrix views with one row or column 
          * faster generation of random numbers
          * faster element access in fixed size matrices
          * better detection of vector expressions by sum(), cumsum(),
            prod(), min(), max(), mean(), median(), stddev(), var() 
          * expressions X=A.i()*B and X=inv(A)*B are automatically converted
            to X=solve(A,B) 

0.2.40  2012-04-04

    o   Upgraded to Armadillo release 2.99.4 "Antarctic Chilli Ranch (Beta 4)"

          * fixes for handling expressions with fixed size matrices

0.2.39  2012-04-02

    o   Upgraded to Armadillo release 2.99.3 "Antarctic Chilli Ranch (Beta 3)"

          * faster repmat()
          * workarounds for braindead compilers (eg. Visual Studio)

0.2.38  2012-03-28

    o   Upgraded to Armadillo release 2.99.2 "Antarctic Chilli Ranch (Beta 2)"

          * added .i()
          * much faster handling of .col() and .row()
          * expressions X=A.i()*B and X=inv(A)*B are automatically converted
            to X=solve(A,B) 

0.2.37  2012-03-19

    o   Upgraded to Armadillo release 2.99.1 "Antarctic Chilli Ranch (Beta 1)"

          * added non-contiguous submatrix views
          * added hist() and histc()
          * faster handling of submatrix views
          * faster generation of random numbers
          * faster element access in fixed size matrices
          * better detection of vector expressions by sum(), cumsum(),
            prod(), min(), max(), mean(), median(), stddev(), var() 

Courtesy of CRANberries, there is also a diffstat report for 0.3.0 relative to 0.2.36 As always, more detailed information is on the RcppArmadillo page. Questions, comments etc should go to the rcpp-devel mailing list off the R-Forge page.

/code/rcpp | permanent link

Mon, 09 Apr 2012

RcppDE 0.1.1
The RcppDE package required a bug-fix release. One of the tests compared results to those from the DEoptim package this is based upon, and these are no longer equal, leading the tests to fail. While I was at it, I finally committed a few more things that had piled up. Below are the corresponding ChangeLog entries

2012-04-08  Dirk Eddelbuettel  

        * DESCRIPTION: Release 0.1.1

        * tests/compTest.R: With the just-release DEoptim 2.2.0, results are
        no longer identical so we commented-out the stopifnot() comparison to
        not break any automated tests (as requested by the CRAN maintainers)

        * .Rbuildignore: Added a few more files which R CMD check does not
        want to see in the tarball

2011-03-07  Dirk Eddelbuettel  

        * src/evaluate.h: Also reflect '...' argument from R function we pass
        in, with thanks to Josh Ulrich for the one-line patch

        * R/DEoptim.R: No longer pass environment 'env' down
        * man/DEoptim.Rd: No longer document now unused 'env'

        * src/deoptim.cpp: Minor tweak to RcppArmadillo object creation

/code/rcpp | permanent link

Wed, 28 Mar 2012

RcppArmadillo 0.2.37 and 0.2.38 released, but not on CRAN
Conrad is readying his fabulous Armadillo C++ template library for linear algebra for a new 3.0.0 release, and started to make pre-releases. His version 2.99.1 came about a good week ago, it took us a few days to make a small required change in RcppArmadillo (which is our R package providing Armadillo to R via Rcpp) but our release 0.2.37 was ready last weekend.

But then the good folks at CRAN did not want it. That is at the same time disappointing to us as developers / maintainers: work we do will not get pushed to largest number of users immediately. On the other hand, we do understand that CRAN is under a lot of strain. Years ago John Fox demonstrated exponential growth of packages at CRAN, the rate was then around 40% per year. Right now the number of packages exceeds 3600, and there are often several dozen daily updates (which you can follow with the CRANberries service for html and rss I had set up years ago). And the three CRAN maintainers all have full-time jobs as academics, and they also happen to be busy R Core members. Plus the new R version 2.15.0 is to be released at the end of the week, and this usually entails a number of package changes, putting extra strain on CRAN right now. For more on new or updated CRAN policies, see this long thread.

Now, as I wrote on the rcpp-devel list, there is of course always install.packages("RcppArmadillo", repos="http://R-Forge.R-project.org") for a direct installation from R-Forge. But as I just put 0.2.38 there, it may take the running of the batch updates on the site so if you want it now, follow this link to my local Rcpp archive.

All that said, here are the NEWS entries for these two last releases:

0.2.38  2012-03-28

    o   Upgraded to Armadillo release 2.99.2 "Antarctic Chilli Ranch (Beta 2)"

          * added .i()
          * much faster handling of .col() and .row()
          * expressions X=A.i()*B and X=inv(A)*B are automatically converted
            to X=solve(A,B) 

0.2.37  2012-03-19

    o   Upgraded to Armadillo release 2.99.1 "Antarctic Chilli Ranch (Beta 1)"

          * added non-contiguous submatrix views
          * added hist() and histc()
          * faster handling of submatrix views
          * faster generation of random numbers
          * faster element access in fixed size matrices
          * better detection of vector expressions by sum(), cumsum(),
            prod(), min(), max(), mean(), median(), stddev(), var() 

As always, more detailed information is on the RcppArmadillo page. Questions, comments etc should go to the rcpp-devel mailing list off the R-Forge page.

/code/rcpp | permanent link

Sat, 24 Mar 2012

Initial release 0.1.0 of package RcppSMC
Hm, I realized that I announced this on Google+ (via Rcpp) as well as on Twitter, on the r-packages list, wrote a new and simple web page for it, but had not put it on my blog. So here is some catching up.

Sequential Monte Carlo / Particle Filter is a (to quote the Wikipedia page I just linked to) sophisticated model estimation technique based on simulation. They are related to both Kalman Filters, and Markov Chain Monte Carlo methods.

Adam Johansen has a rather nice set of C++ classes documentated in his 2009 paper in the Journal of Statistical Software (JSS). I started to play with these classes and realized that, once again, this would make perfect sense in an R extension built with the Rcpp package by Romain and myself (and in JSS too). So I put a first prototype onto R-Forge and emailed Adam who, to my pleasant surprise, was quite interested. And a couple of emails, and commits later, we are happy to present a very first release 0.1.0.

I wrote a few words on a RcppSMC page on my website where you can find a few more details. But in short, we already have example functions demonstrating the backend classes by reproducing examples from

Johansen (2009)
and his example 5.1 via pfLineartBS() for a linear bootstrap example;
Doucet, Briers and Senecal (2006)
and their (optimal) block-sampling particle filter for a linear Gaussian model (serving as an illustration as the setup does of course have an analytical solution) via the function blockpfGaussianOpt()
Gordon, Salmond and Smith (1993)
and their ubiqitous nonlinear state space model via the function pfNonlinBS().

And to illustrate just why Rcpp is so cool for this, here is a little animation of a callback from the C++ code when doing the filtering on Adam's example 5.1. By passing a simple plotting function, written in R, to the C++ code, we can get a plot updated on every iteration. Here I cheated a little and used our old plot function with fixed ranges, the package now uses a more general function:

Example of RcppSMC callback to R plot when estimation example 5.1 from Johansen (2009)

The animation is of course due to ImageMagick glueing one hundred files into a single animated gif.

More information about RcppSMC is on its page, and we intend to add more examples and extensions over time.

/code/rcpp | permanent link

Tue, 06 Mar 2012

RcppArmadillo 0.2.36
RcppArmadillo release 0..2.36 is now on CRAN. It contains just the changes from the new Armadillo release 2.4.4. The NEWS entry below summarises the changes.

0.2.36  2012-03-05

    o   Upgraded to Armadillo release 2.4.4

          * fixes for qr() and syl()
          * more portable wall_clock class
          * faster relational operators on submatrices

Courtesy of CRANberries, there is also a diffstat reports for 0.2.36 relative to 0.2.35 As always, more detailed information is on the RcppArmadillo page. Questions, comments etc should go to the rcpp-devel mailing list off the R-Forge page.

/code/rcpp | permanent link

Fri, 17 Feb 2012

RcppArmadillo 0.2.35
Now that Rcpp 0.9.10 is released and on CRAN, other packages can take advantage of a small change needed to make use of the quasi-output stream Rcpp::Rcout. So the new release 0.2.35 of RcppArmadillo does just that---and input/output from Armadillo, the wonderful linear algebra / math library for C++ written chiefly by Conrad Sanderson now comes through in a coordinated buffered fashion. As as std::cout is no longer used by default, the R CMD check no longer flags this.

There are two more bugfixes in the releases for issues noticed by attentive RcppArmadillo users. Teo Guo Ci spotted a missing semicolon when C++0x code was activated, and Gershon Bialer suggested a fix for an issue plagueing users of the jurassic g++ 4.2.1 compiler which Apple forces on users of OS X. We thank Martin Renner for testing these fixes. The NEWS entry below summarises the changes.

0.2.35  2012-02-17

    o   Upgraded to Armadillo release 2.4.3

          * Support for ARMA_DEFAULT_OSTREAM using Rcpp::Rcout added

    o   Minor bug fix release improving corner cases affecting builds:

          * Missing semicolon added in Mat_meat (when in C++0x mode), with
            thanks to Teo Guo Ci 
          * Armadillo version vars now instantiated in RcppArmadillo.cpp
            which helps older g++ versions, with thanks to Gershon Bialer
          * Thanks also to Martin Renner for testing these changes

          * Unit tests output fallback directory changed per Brian Ripley's
            request to not ever use /tmp

          * Minor update to version numbers in RcppArmadillo-package.Rd

Courtesy of CRANberries, there is also a diffstat reports for 0.2.35 relative to 0.2.34 As always, more detailed information is on the RcppArmadillo page. Questions, comments etc should go to the rcpp-devel mailing list off the R-Forge page.

/code/rcpp | permanent link

Rcpp 0.9.10
A new release 0.9.10 of Rcpp is now on CRAN and in Debian. This is mostly internal release with a little bit of code reorgination (some of which will be used by a forthcoming RcppArmadillo release), some changes to make R CMD check happy, and one or two new features.

The complete NEWS entry for 0.9.10 is below; more details are in the ChangeLog file in the package and on the Rcpp Changelog page.

0.9.10  2012-02-16

    o   Rearrange headers so that Rcpp::Rcout can be used by RcppArmadillo et al

    o   New Rcpp sugar function mapply (for limited to two or three input vectors)

    o   Added custom version of the Rcpp sugar diff function for numeric vectors
        skipping unncesserry checks for NA

    o   Some internal code changes to reflect changes and stricter requirements
        in R CMD check in the current R-devel versions
    
    o   Corrected fixed-value initialization for IntegerVector (with thanks to
        Gregor Kastner for spotting this)

    o   New Rcpp-FAQ entry on simple way to a set compiler option for cxxfunction

Thanks to CRANberries, you can also look at a diff to the previous release 0.9.9. As always, even fuller details are on the Rcpp Changelog page and the Rcpp page which also leads to the downloads, the browseable doxygen docs and zip files of doxygen output for the standard formats. A local directory has source and documentation too. Questions, comments etc should go to the rcpp-devel mailing list off the R-Forge page

/code/rcpp | permanent link

Fri, 30 Dec 2011

RcppExamples 0.1.3
A minor new release of the RcppExamples package is now on CRAN. RcppExamples contains a few illustrations of how to use Rcpp. It grew out of documentation for the classic API (now in its own package RcppClassic), and while we added a few more functions documenting how to do the same with the new API, the package is still nowhere near completion.

The two ChangeLog entries since the last release are below. One new example was added, and some things were changed in order to make R CMD check (and the CRAN gate keepers) happy.

2011-12-28  Dirk Eddelbuettel  

        * DESCRIPTION: Release 0.1.3

        * src/newRcppDateExample.cpp: switch from std::cout to the new
        Rcpp::Rcout device available since Rcpp 0.9.8
        * src/classicRcppDateExample.cpp: idem

        * DESCRIPTION: Depends on Rcpp (>= 0.9.9) for Rcpp::Rcout

2011-04-08  Dirk Eddelbuettel  

        * R/RcppDataFrame.R: Added new example for Rcpp::DataFrame
        * src/RcppDataFrame.cpp: C++ source for new example
        * man/RcppDataFrame.Rd: Documentation

        * man/RcppParams.Rd: Small change to suppres a warning
Thanks to CRANberries, you can also look at a diff to the previous release 0.1.2. Questions, comments etc should go to the rcpp-devel mailing list off the R-Forge page

/code/rcpp | permanent link

Tue, 27 Dec 2011

Rcpp 0.9.9
Release 0.9.9 of Rcpp is now on CRAN and getting into Debian too. This is mainly a bug fix release: our addition of int64 support in 0.9.8 came at the expense of support for long and unsigned long which broke some packages using Rcpp, and expecting those types. Ooops.

The complete NEWS entry for 0.9.9; more details are in the ChangeLog file in the package and on the Rcpp Changelog page.

0.9.9   2012-12-25

    o   Reverting the 'int64' changes from release 0.9.8 which adversely
        affect packages using Rcpp: We will re-apply the 'int64' changes in a 
        way which should cooperate more easily with 'long' and 'unsigned long'.

    o   Unit test output directory fallback changed to use Rcpp.Rcheck

    o   Conditioned two unit tests to not run on Windows where they now break
        whereas they passed before, and continue to pass on other OSs

Thanks to CRANberries, you can also look at a diff to the previous release 0.9.8. As always, even fuller details are on the Rcpp Changelog page and the Rcpp page which also leads to the downloads, the browseable doxygen docs and zip files of doxygen output for the standard formats. A local directory has source and documentation too. Questions, comments etc should go to the rcpp-devel mailing list off the R-Forge page

/code/rcpp | permanent link

Thu, 22 Dec 2011

Rcpp 0.9.8
A new release 0.9.8 of Rcpp is now on CRAN and will also get into Debian shortly (once I finish building R 2.14.1).

This release contains a few incremental changes. Romain, sponsored by by the Open Source Programs Office at Google, had released a new package int64 bringing larger integers to R, and this is now supported by Rcpp as well. John Chambers contributed some code to have Reference Classes extend existing C++ classes (typically brought in via Rcpp Modules). Jelmer Ypma sent us a patch to add a Rcout device not unlike cout, but aligned with R's io buffering. We added some more unit tests, and made a few small fixes here or there.

The complete NEWS entry is below; more details are in the ChangeLog file in the package and on the Rcpp Changelog page.

0.9.8   2011-12-21

    o   wrap now handles 64 bit integers (int64_t, uint64_t) and containers 
        of them, and Rcpp now depends on the int64 package (also on CRAN).
        This work has been sponsored by the Google Open Source Programs
        Office.

    o   Added setRcppClass() function to create extended reference classes 
        with an interface to a C++ class (typically via Rcpp Module) which
        can have R-based fields and methods in addition to those from the C++.

    o   Applied patch by Jelmer Ypma which adds an output stream class
        'Rcout' not unlike std::cout, but implemented via Rprintf to
        cooperate with R and its output buffering.
        
    o   New unit tests for pf(), pnf(), pchisq(), pnchisq() and pcauchy()

    o   XPtr constructor now checks for corresponding type in SEXP

    o   Updated vignettes for use with updated highlight package

    o   Update linking command for older fastLm() example using external 
        Armadillo

Thanks to CRANberries, you can also look at a diff to the previous release 0.9.7. As always, even fuller details are on the Rcpp Changelog page and the Rcpp page which also leads to the downloads, the browseable doxygen docs and zip files of doxygen output for the standard formats. A local directory has source and documentation too. Questions, comments etc should go to the rcpp-devel mailing list off the R-Forge page

/code/rcpp | permanent link

Tue, 13 Dec 2011

RcppArmadillo 0.2.34
And another quick bugfix release by Conrad Sanderson made it version 2.4.2 bug of Armadillo. And this is in RcppArmadillo release 0.2.34 which got to CRAN this morning The NEWS entry below summarises the changes.

0.2.34	2011-12-12

    o   Upgraded to Armadillo release 2.4.2

          * clarified documentation for .reshape()
          * fix for handling of empty matrices by .resize()

Courtesy of CRANberries, there is also a diffstat reports for 0.2.34 relative to 0.2.33 As always, more detailed information is on the RcppArmadillo page. Questions, comments etc should go to the rcpp-devel mailing list off the R-Forge page.

/code/rcpp | permanent link