Sun, 24 Jan 2016

RcppExamples 0.1.7

After an usually long hiatus, the RcppExamples package has been updated once more: a new version 0.1.7 is now on CRAN.

The RcppExamples provides a handful of short examples detailing by concrete working examples how to set up basic R data structures in C++. In this version, essentially all files (C++, R as well as manual pages) were refreshed, along with the usual set of small changes to bring the package to current R CMD check standards.

A NEWS extract follows:

Changes in RcppExamples version 0.1.7 (2016-01-23)

  • All examples were updated to use Rcpp Attributes and (where possible) use const & interfaces.

  • Updated DESCRIPTION for current R CMD check standards

  • The Rcpp package is now imported rather than depended upon.

  • Added README.md as well as .travis.yml.

  • Also updated and refreshed all manual pages and R files.

Courtesy of CRANberries, there is also a diffstat report for the most recent release.

This post by Dirk Eddelbuettel originated on his Thinking inside the box blog. Please report excessive re-aggregation in third-party for-profit settings.

/code/rcpp | permanent link

Fri, 22 Jan 2016

RcppEigen 0.3.2.7.0

A new minor release of RcppEigen is now on CRAN and in Debian. It primarily upgrades to the recent 3.2.7 release of Eigen -- thanks once again to fine work by Yixuan Qiu. We also have one additonal PR by Alexey Stukalow who ensured that the fastLm() example will work fine with when the Intel MKL is used.

The NEWS file entry follows.

Changes in RcppEigen version 0.3.2.7.0 (2016-01-18)

  • Updated to version 3.2.7 of Eigen

  • The fastLm example will not include the Lapack header if MKL is defined (thanks to PR #25 by Alexey Stukalow)

Courtesy of CRANberries, there is also a diffstat report for the most recent release.

This post by Dirk Eddelbuettel originated on his Thinking inside the box blog. Please report excessive re-aggregation in third-party for-profit settings.

/code/rcpp | permanent link

RcppCCTZ 0.0.3

Bradley White from the upstream CCTZ team prepared some more changes in CCTZ itself -- so a new RcppCCTZ version got to CRAN the other day catching up with these changes.

CCTZ is a C++ library for translating between absolute and civil times using the rules of a time zone. It requires only a proper C++11 compiler and the standard IANA time zone data base which standard Unix, Linux, OS X, ... computers tend to have in /usr/share/zoneinfo. RcppCCTZ connects this library to R by relying on Rcpp.

Changes in this version are summarized here:

Changes in version 0.0.3 (2016-01-17)

  • Synchronized with CCTZ upstream.

We also have a diff to the previous version thanks to CRANberries.

More details, issue tickets etc at the GitHub repository.

This post by Dirk Eddelbuettel originated on his Thinking inside the box blog. Please report excessive re-aggregation in third-party for-profit settings.

/code/rcpp | permanent link

Sun, 10 Jan 2016

Rcpp 0.12.3: Keep rollin'

The third update in the 0.12.* series of Rcpp arrived on the CRAN network for GNU R earlier today, and has been pushed to Debian. It follows the 0.12.0 release from late July, the 0.12.1 release in September, and the 0.12.2 release in November making it the seventh release at the steady bi-montly release frequency. This release is somewhat more of a maintenance release addressing a number of small bugs and nuisances without adding any new features.

Rcpp has become the most popular way of enhancing GNU R with C or C++ code. As of today, 553 packages on CRAN depend on Rcpp for making analytical code go faster and further. That is up by more than fourty packages from the last release in November.

Once again, we have new first-time contributors. Kazuki Fukui corrected an issue he encountered when having CLion re-formatted some code for him. Joshua Pritikin corrected a constructor initialization. Of course, we also had several pull reports from regular contributors -- see below for a detailed list of changes extracted from the NEWS file.

Changes in Rcpp version 0.12.3 (2016-01-10)

  • Changes in Rcpp API:

    • Const iterators now CharacterVector now behave like regular iterators (PR #404 by Dan fixing #362).

    • Math operators between matrix and scalars type have been added (PR #406 by Qiang fixing #365).

    • A missing std::hash function interface for Rcpp::String has been addded (PR #408 by Qiang fixing #84).

  • Changes in Rcpp Attributes:

    • Avoid invalid function names when generating C++ interfaces (PR #403 by JJ fixing #402).

    • Insert additional space around & in function interface (PR #400 by Kazuki Fukui fixing #278).

  • Changes in Rcpp Modules:

    • The copy constructor now initialized the base class (PR #411 by Joshua Pritikin fixing #410)

  • Changes in Rcpp Repository:

    • Added a file Contributing.md providing some points to potential contributors (PR #414 closing issue #413)

Thanks to CRANberries, you can also look at a diff to the previous release. As always, even fuller details are on the Rcpp Changelog page and the Rcpp page which also leads to the downloads page, 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.

This post by Dirk Eddelbuettel originated on his Thinking inside the box blog. Please report excessive re-aggregation in third-party for-profit settings.

/code/rcpp | permanent link

Sat, 19 Dec 2015

RcppTOML 0.0.5

After a short hiatus, a new version of the (wonderfully useful, if I dare say so ;-) RcppTOML package is now on CRAN. RcppTOML lets R read the (absolutely awesome) TOML configuration file format--which is simply fabulous as it emphasizes strong readability for humans while at the same time supporting strong typing as well as immediate and clear error reports. At work, we're all fans now.

The new version on CRAN mostly updates to an updated version of the underlying cpptoml library by Chase. Nothing much changed on the R side.

Courtesy of CRANberries, there is a diffstat report for this release More information and examples are on the RcppTOML page.

This post by Dirk Eddelbuettel originated on his Thinking inside the box blog. Please report excessive re-aggregation in third-party for-profit settings.

/code/rcpp | permanent link

Wed, 16 Dec 2015

RcppArmadillo 0.6.400.2.2

armadillo image

And yet another updated of Armadillo by Conrad bringing us to 6.400.2. I folded that yesterday into RcppArmadillo 0.6.400.2.2; and this is now on CRAN and Debian. There was even an interim-CRAN-only release 0.6.300.2.2 with a refinement for tests of imcompleye LAPACK libraries---which we encounter whenver R is build with its own (partial) copy of LAPACK as on Windows, and on bigger computers whenver this was chosen over the default of system LAPACK.

Armadillo is a powerful and expressive C++ template library for linear algebra aiming towards a good balance between speed and ease of use with a syntax deliberately close to a Matlab.

This release brings the following changes:

Changes in RcppArmadillo version 0.6.400.2.0 (2015-12-15)

  • Upgraded to Armadillo 6.400.2 ("Flying Spaghetti Monster Deluxe")

    • expanded each_col(), each_row() and each_slice() to handle C++11 lambda functions

    • added ind2sub() and sub2ind()

    • fixes for corner cases in gmm_diag class

Changes in RcppArmadillo version 0.6.300.2.2 (2015-12-12)

  • Upgraded to Armadillo 6.300.3-test ("Flying Spaghetti Monster")

    • Additional test in auxlib_meat.hpp for limited LAPACK

  • Updated test and #define for limited LAPACK version R might be built with on Unix-alike systems

Courtesy of CRANberries, there is also a diffstat report for the most recent CRAN 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.

This post by Dirk Eddelbuettel originated on his Thinking inside the box blog. Please report excessive re-aggregation in third-party for-profit settings.

/code/rcpp | permanent link

Fri, 04 Dec 2015

RcppArmadillo 0.6.200.3.0

armadillo image

The regular monthly upstream Armadillo update gave us the second update in the 6.* series: version 6.300.2. This was rolled into RcppArmadillo 0.6.300.2 which was once again tested against all reverse-dependencies before being sent to CRAN and Debian where the new packages arrived yesterday.

Besides the changes by Conrad, this version of RcppArmadillo also contains a really nice pull request by Nathan Russell which adds input conversion support for Armadillo Cube types, templated to all common inputs, and along with proper unit tests. Thanks!

Armadillo is a powerful and expressive C++ template library for linear algebra aiming towards a good balance between speed and ease of use with a syntax deliberately close to a Matlab.

This release brings the following changes:

Changes in RcppArmadillo version 0.6.300.2.0 (2015-12-03)

  • Upgraded to Armadillo 6.300.2 ("Flying Spaghetti Monster")

    • expanded solve() to find approximate solutions for rank-deficient systems

    • faster handling of non-contiguous submatrix views in compound expressions

    • added .for_each() to Mat, Row, Col, Cube and field classes

    • added rcond() for estimating the reciprocal condition number

    • fixes for spsolve(), eigs_sym(), eigs_gen(), svds()

  • Added support for Cube types via as<> converters (PR #64 by Nathan Russell, fixing #63 and #42)

Courtesy of CRANberries, there is also a diffstat report for the most recent CRAN 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.

This post by Dirk Eddelbuettel originated on his Thinking inside the box blog. Please report excessive re-aggregation in third-party for-profit settings.

/code/rcpp | permanent link

Wed, 02 Dec 2015

RcppCCTZ 0.0.2 -- now with Solaris support

Following on yesterday's announcement of RcppCCTZ, what is the only thing better than another date, time, or timezones library package? One that works on Solaris too :)

Bradley White from CCTZ upstream spotted the failed compilation on the machine in Oxford and suggested a quick fix. Jeroen quickly tested what I had put into a branch, and there we have it: version 0.0.2 which now builds everywhere.

Changes (for both releases) are summarized here:

Changes in version 0.0.2 (2015-12-02)

  • Additional #ifdef statements suggested by Bradley White in CCTZ ticket #5 permitting compilation on Solaris – with thanks to Jeroen for testing our branch.

Changes in version 0.0.1 (2015-12-01)

  • Initial CRAN upload.

  • Package is functional and provides examples.

We now also have a diff to the previous version thanks to CRANberries.

More details, issue tickets etc at the GitHub repository.

This post by Dirk Eddelbuettel originated on his Thinking inside the box blog. Please report excessive re-aggregation in third-party for-profit settings.

/code/rcpp | permanent link

Tue, 01 Dec 2015

RcppCCTZ 0.0.1

A new package! A couple of weeks ago folks at Google released CCTZ: a C++ library for translating between absolute and civil times using the rules of a time zone. It requires only a proper C++11 compiler and the standard IANA time zone data base which standard Unix, Linux, OS X, ... computers tend to have in /usr/share/zoneinfo.

And as the world needs nothing more than additional date, time, or timezones libraries, I started to quickly create a basic R wrapper package. This stalled as the original version of CCTZ used an __int128 for extended precision. That is not only not portable, but also prohibits compilation on baby computers still running a 32 OS (such as my trusted X1 laptop merrily plugging along with 4 gb of ram under Linux). Hence I filed an issue ticket which, lo and behold, got resolved two days ago.

And so now we have a shiny new RcppCCTZ package on CRAN in a very basic version 0.0.1. It happily runs all the original examples from CCTZ as e.g. this one:

// from examples/hello.cc
//
// [[Rcpp::export]]
int helloMoon() {
    cctz::TimeZone syd;
    if (!cctz::LoadTimeZone("Australia/Sydney", &syd)) return -1;

    // Neil Armstrong first walks on the moon
    const auto tp1 = cctz::MakeTime(1969, 7, 21, 12, 56, 0, syd);

    const std::string s = cctz::Format("%F %T %z", tp1, syd);
    Rcpp::Rcout << s << "\n";

    cctz::TimeZone nyc;
    cctz::LoadTimeZone("America/New_York", &nyc);

    const auto tp2 = cctz::MakeTime(1969, 7, 20, 22, 56, 0, nyc);
    return tp2 == tp1 ? 0 : 1;
}

which results in

R> library(RcppCCTZ)
R> helloMoon()
1969-07-21 12:56:00 +1000
[1] 0
R>

indicating that the two civil times in fact correspond to the same absolute times when Armstrong walked on the moon.

If you want to learn more about CCTZ, there was a corresponding talk CppCon (Youtube, Slides).

I hope this provides a starting point for some new interesting computation on time from R. Collaboration welcome via the RcppCCTZ GitHub repo.

This post by Dirk Eddelbuettel originated on his Thinking inside the box blog. Please report excessive re-aggregation in third-party for-profit settings.

/code/rcpp | permanent link

Mon, 16 Nov 2015

RcppAnnoy 0.0.7

A new version of RcppAnnoy, our Rcpp-based R integration of the nifty Annoy library by Erik, is now on CRAN. Annoy is a small, fast, and lightweight C++ template header library for approximate nearest neighbours.

This release mostly just catches up with the Annoy release 1.6.2 of last Friday. No new features were added on our side.

Courtesy of CRANberries, there is also a diffstat report for this release.

This post by Dirk Eddelbuettel originated on his Thinking inside the box blog. Please report excessive re-aggregation in third-party for-profit settings.

/code/rcpp | permanent link

Sun, 15 Nov 2015

Rcpp 0.12.2: More refinements

The second update in the 0.12.* series of Rcpp is now on the CRAN network for GNU R. As usual, I will also push a Debian package. This follows the 0.12.0 release from late July which started to add some serious new features, and builds upon the 0.12.1 release in September. It also marks the sixth release this year where we managed to keep a steady bi-montly release frequency.

Rcpp has become the most popular way of enhancing GNU R with C or C++ code. As of today, 512 packages on CRAN depend on Rcpp for making analytical code go faster and further. That is up by more than fifty package from the last release in September (and we recently blogged about crossing 500 dependents).

This release once again features pull requests from two new contributors with Nathan Russell and Tianqi Chen joining in. As shown below, other recent contributors (such as such as Dan) are keeping at it too. Keep'em coming! Luke Tierney also email about a code smell he spotted and which we took care of. A big Thank You! to everybody helping with code, bug reports or documentation. See below for a detailed list of changes extracted from the NEWS file.

Changes in Rcpp version 0.12.2 (2015-11-14)

  • Changes in Rcpp API:

    • Correct return type in product of matrix dimensions (PR #374 by Florian)

    • Before creating a single String object from a SEXP, ensure that it is from a vector of length one (PR #376 by Dirk, fixing #375).

    • No longer use STRING_ELT as a left-hand side, thanks to a heads-up by Luke Tierney (PR #378 by Dirk, fixing #377).

    • Rcpp Module objects are now checked more carefully (PR #381 by Tianqi, fixing #380)

    • An overflow in Matrix column indexing was corrected (PR #390 by Qiang, fixing a bug reported by Allessandro on the list)

    • Nullable types can now be assigned R_NilValue in function signatures. (PR #395 by Dan, fixing issue #394)

    • operator<<() now always shows decimal points (PR #396 by Dan)

    • Matrix classes now have a transpose() function (PR #397 by Dirk fixing #383)

    • operator<<() for complex types was added (PRs #398 by Qiang and #399 by Dirk, fixing #187)

  • Changes in Rcpp Attributes:

    • Enable export of C++ interface for functions that return void.

  • Changes in Rcpp Sugar:

    • Added new Sugar function cummin(), cummax(), cumprod() (PR #389 by Nathan Russell fixing #388)

    • Enabled sugar math operations for subsets; e.g. x[y] + x[z]. (PR #393 by Kevin and Qiang, implementing #392)

  • Changes in Rcpp Documentation:

    • The NEWS file now links to GitHub issue tickets and pull requests.

    • The Rcpp.bib file with bibliographic references was updated.

Thanks to CRANberries, you can also look at a diff to the previous release As always, even fuller details are on the Rcpp Changelog page and the Rcpp page which also leads to the downloads page, 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.

This post by Dirk Eddelbuettel originated on his Thinking inside the box blog. Please report excessive re-aggregation in third-party for-profit settings.

/code/rcpp | permanent link

Sat, 31 Oct 2015

RcppArmadillo 0.6.200.2.0

armadillo image

Yet another monthly upstream Armadillo update gets us the first changes to the new the 6.* series. This was preceded by two uploads of test released to GitHub-only. These two were tested both against all reverse-dependencies as usual. A matching upload to Debian will follow shortly.

Armadillo is a powerful and expressive C++ template library for linear algebra aiming towards a good balance between speed and ease of use with a syntax deliberately close to a Matlab.

This release is fairly straightforward with few changes:

Changes in RcppArmadillo version 0.6.200.2.0 (2015-10-31)

  • Upgraded to Armadillo 6.200.0 ("Midnight Blue Deluxe")

    • expanded diagmat() to handle non-square matrices and arbitrary diagonals

    • expanded trace() to handle non-square matrices

Courtesy of CRANberries, there is also a diffstat report for the most recent CRAN 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.

This post by Dirk Eddelbuettel originated on his Thinking inside the box blog. Please report excessive re-aggregation in third-party for-profit settings.

/code/rcpp | permanent link

Tue, 27 Oct 2015

Rcpp now used by over 500 CRAN packages

500 Rcpp packages

This morning, Rcpp reached another round milestone: 501 packages on CRAN now depend on it (as measured by Depends, Imports and LinkingTo declarations, and even excluding one or two packages with an accidental declaration that do not use it). The graph is on the left depicts the growth of Rcpp usage over time. And there are a full seventy more on BioConductor in its development branch (but BioConductor is not included in the chart).

Rcpp cleared 300 packages less than a year ago. It passed 400 packages in June when I only tweeted about it this June (while traveling for Rcpp training at U Zuerich, the R Summit at CBS, and the fabulous useR! 2015 at U Aalborg; so no blog post). The first and less detailed part uses manually saved entries, the second half of the data set was generated semi-automatically via a short script appending updates to a small file-based backend. A list of user package is kept on this page.

Also displayed in the graph is the relative proportion of CRAN packages using Rcpp. The four per-cent hurdle was cleared just before useR! 2014 where I showed a similar graph (as two distinct graphs) in my invited talk. We passed five percent in December of last year, six percent this July and now stand at 6.77 percent, or about one in fourteen R packages.

500 user packages is very humbling, a staggering number and a big responsibility. We will out best try to keep Rcpp as performant and reliable as it has been so that the next set of packages can rely on it---just like these 500 do.

So with that a very big Thank You! to all users and contributors of Rcpp for help, suggestions, bug reports, documentation or, of course, code.

This post by Dirk Eddelbuettel originated on his Thinking inside the box blog. Please report excessive re-aggregation in third-party for-profit settings.

/code/rcpp | permanent link

Tue, 06 Oct 2015

RcppRedis 0.1.6

An incremental RcppRedis release arrived on CRAN yesterday. Russell Pierce contributed four new function for pushing and popping to/from lists, and added authentication support. I added a simple ping command as well.

Changes in version 0.1.6 (2015-10-05)

  • Added support (including new unit tests) for lpop, rpop, lpush, rpush as well as auth via augmented constructor (all thanks to PRs #11 and #13 by Russell Pierce)

  • Added ping command and unit test

Courtesy of CRANberries, there is also a diffstat report for the most recent release. More information is on the RcppRedis page.

This post by Dirk Eddelbuettel originated on his Thinking inside the box blog. Please report excessive re-aggregation in third-party for-profit settings.

/code/rcpp | permanent link

Sun, 04 Oct 2015

RcppArmadillo 0.6.100.0.0

armadillo image

The somewhat regular monthly upstream Armadillo update brings us a first release of the 6.* series. This follows an earlier test release announced on the list, and released to the Rcpp drat. And as version 6.100.0 was released on Friday by Conrad, we rolled it into RcppArmadillo release 0.6.100.0.0 yesterday. Following yet another full test against all reverse dependencies, got uploaded to CRAN which has now accepted it. A matching upload to Debian will follow shortly.

Armadillo is a powerful and expressive C++ template library for linear algebra aiming towards a good balance between speed and ease of use with a syntax deliberately close to a Matlab.

This release a few changes:

Changes in RcppArmadillo version 0.6.100.0.0 (2015-10-03)

  • Upgraded to Armadillo 6.100.0 ("Midnight Blue")

    • faster norm() and normalise() when using ATLAS or OpenBLAS

    • added Schur decomposition: schur()

    • stricter handling of matrix objects by hist() and histc()

    • advanced constructors for using auxiliary memory by Mat, Col, Row and Cube now have the default of strict = false

    • Cube class now delays allocation of .slice() related structures until needed

    • expanded join_slices() to handle joining cubes with matrices

Courtesy of CRANberries, there is also a diffstat report for the most recent CRAN 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.

This post by Dirk Eddelbuettel originated on his Thinking inside the box blog. Please report excessive re-aggregation in third-party for-profit settings.

/code/rcpp | permanent link

Thu, 24 Sep 2015

RcppEigen 0.3.2.5.1

A bugfix release of RcppEigen is now on CRAN and in Debian. The NEWS file entry follows.

Changes in RcppEigen version 0.3.2.5.1 (2015-09-23)

  • Corrected use of kitten() thanks to Grant Brown (#21)

  • Applied upstream change to protect against undefined behaviour with null pointers

Courtesy of CRANberries, there is also a diffstat report for the most recent release.

This post by Dirk Eddelbuettel originated on his Thinking inside the box blog. Please report excessive re-aggregation in third-party for-profit settings.

/code/rcpp | permanent link

Sun, 20 Sep 2015

RcppArmadillo 0.5.600.2.0

armadillo image

And yet another upstream Armadillo update -- version 5.600.2 was released yesterday by Conrad. So I pushed a new and matching RcppArmadillo release 0.5.600.2.0 to CRAN and to Debian.

Armadillo is a powerful and expressive C++ template library for linear algebra aiming towards a good balance between speed and ease of use with a syntax deliberately close to a Matlab.

This release contains small upstream improvements:

Changes in RcppArmadillo version 0.5.600.2.0 (2015-09-19)

  • Upgraded to Armadillo 5.600.2 ("Molotov Cocktail Deluxe")

    • expanded .each_col() and .each_row() to handle out-of-place operations

    • added .each_slice() for repeated matrix operations on each slice of a cube

    • faster handling of compound expressions by join_rows() and join_cols()

Courtesy of CRANberries, there is also a diffstat report for the most recent CRAN 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.

This post by Dirk Eddelbuettel originated on his Thinking inside the box blog. Please report excessive re-aggregation in third-party for-profit settings.

/code/rcpp | permanent link

Thu, 10 Sep 2015

Rcpp 0.12.1: First boat load of fixes!

The first updated in the 0.12.* series of Rcpp is now on the CRAN network for GNU R this morning, and I will push a Debian package. This follows the 0.12.0 release from late July which started to some serious new features.

Rcpp has become the most popular way of enhancing GNU R with C++ code. As of today, 461 packages on CRAN depend on Rcpp for making analyses go faster and further.

This release once again features contributions from a number of new contributors, with Florian Plaza Oñate and Dan Dillon joining the fray with several pull requests each. Kurt Hornik also helped with a fix for a bad interaction between very recent R (3.2.2) changes and Rcpp; another related one was also addressed. A big Thanks! to everybody helping with code, bug reports or documentation, See below for a detailed list of changes extracted from the NEWS file.

Changes in Rcpp version 0.12.1 (2015-09-10)

  • Changes in Rcpp API:

    • Correct use of WIN32 instead of _WIN32 to please Windows 10

    • Add an assignment operator to DimNameProxy (PR #339 by Florian)

    • Add vector and matrix accessors .at() with bounds checking (PR #342 by Florian)

    • Correct character vector conversion from single char (PR #344 by Florian fixing issue #343)

    • Correct on use of R_xlen_t back to size_t (PR #348 by Romain)

    • Correct subsetting code to allow for single assignment (PR #349 by Florian)

    • Enable subset assignment on left and righ-hand side (PR #353 by Qiang, fixing issue #345)

    • Refreshed to included tinyformat template library (PR #357 by Dirk, issue #356)

    • Add operator<<() for vectors and matrices (PR #361 by Dan fixing issue #239)

    • Make String and String_Proxy objects comparable (PR #366 and PR #372 by Dan, fixing issue #191)

    • Add a new class Nullable for objects which may be NULL (PR #368 by Dirk and Dan, fixing issue #363)

    • Correct creation and access of large matrices (PR #370 by Florian, fixing issue #369)

  • Changes in Rcpp Attributes:

    • Correctly reset directory in case of no-rebuilding but Windows code (PR #335 by Dirk)

  • Changes in Rcpp Modules:

    • We no longer define multiple Modules objects named World in the unit tests with was seen to have a bad effect with R 3.2.2 or later (PR #351 by Dirk fixing issue #350).

    • Applied patch by Kurt Hornik which improves how Rcpp loads Modules (PR #353 by Dirk)

  • Changes in Rcpp Documentation:

    • The Rcpp.bib file with bibliographic references was updated.

Thanks to CRANberries, you can also look at a diff to the previous release As always, even fuller details are on the Rcpp Changelog page and the Rcpp page which also leads to the downloads page, 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.

This post by Dirk Eddelbuettel originated on his Thinking inside the box blog. Please report excessive re-aggregation in third-party for-profit settings.

/code/rcpp | permanent link

Sat, 05 Sep 2015

RcppDE 0.1.4

A second maintenance release 0.1.4 of our RcppDE package, following on the heels of the recent 0.1.3. release arrived on CRAN today. RcppDE is a "port" of DEoptim, a popular package for derivative-free optimisation using differential optimization, to C++. By using RcppArmadillo, the code becomes a lot shorter and more legible.

This version changes the package-internal code to use Rcpp Attributes which makes things a little simpler (and possibly more robust as well).

Courtesy of CRANberries, there is also a diffstat report for the most recent release.

This post by Dirk Eddelbuettel originated on his Thinking inside the box blog. Please report excessive re-aggregation in third-party for-profit settings.

/code/rcpp | permanent link

Thu, 03 Sep 2015

RcppArmadillo 0.5.500.2.0

armadillo image

Once again time for the monthly upstream Armadillo update -- version 5.500.2 was released earlier today by Conrad. And a new and matching RcppArmadillo release 0.5.500.2.0 in already on CRAN and will go to Debian shortly.

Armadillo is a powerful and expressive C++ template library for linear algebra aiming towards a good balance between speed and ease of use with a syntax deliberately close to a Matlab.

This release contains mostly bug fixes and some internal code refactoring:

Changes in RcppArmadillo version 0.5.500.2.0 (2015-09-03)

  • Upgraded to Armadillo 5.500.2 ("Molotov Cocktail")

    • expanded object constructors and generators to handle size() based specification of dimensions

    • faster handling of submatrix rows

    • faster clamp()

    • fixes for handling sparse matrices

Courtesy of CRANberries, there is also a diffstat report for the most recent CRAN 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.

This post by Dirk Eddelbuettel originated on his Thinking inside the box blog. Please report excessive re-aggregation in third-party for-profit settings.

/code/rcpp | permanent link

Sun, 30 Aug 2015

RcppGSL 0.3.0

A new version of RcppGSL just arrived on CRAN. The RcppGSL package provides an interface from R to the GNU GSL using our Rcpp package.

Following on the heels of an update last month we updated the package (and its vignette) further. One of the key additions concern memory management: Given that our proxy classes around the GSL vector and matrix types are real C++ object, we can monitor their scope and automagically call free() on them rather then insisting on the user doing it. This renders code much simpler as illustrated below. Dan Dillon added const correctness over a series on pull request which allows us to write more standard (and simply nicer) function interfaces. Lastly, a few new typedef declaration further simply the use of the (most common) double and int vectors and matrices.

Maybe a code example will help. RcppGSL contains a full and complete example package illustrating how to write a package using the RcppGSL facilities. It contains an example of computing a column norm -- which we blogged about before when announcing an much earlier version. In its full glory, it looks like this:

#include <RcppGSL.h>
#include <gsl/gsl_matrix.h>
#include <gsl/gsl_blas.h>

extern "C" SEXP colNorm(SEXP sM) {

  try {

        RcppGSL::matrix<double> M = sM;     // create gsl data structures from SEXP
        int k = M.ncol();
        Rcpp::NumericVector n(k);           // to store results

        for (int j = 0; j < k; j++) {
            RcppGSL::vector_view<double> colview = gsl_matrix_column (M, j);
            n[j] = gsl_blas_dnrm2(colview);
        }
        M.free() ;
        return n;                           // return vector

  } catch( std::exception &ex ) {
        forward_exception_to_r( ex );

  } catch(...) {
        ::Rf_error( "c++ exception (unknown reason)" );
  }
  return R_NilValue; // -Wall
}

We manually translate the SEXP coming from R, manually cover the try and catch exception handling, manually free the memory etc pp.

Well in the current version, the example is written as follows:

#include <RcppGSL.h>
#include <gsl/gsl_matrix.h>
#include <gsl/gsl_blas.h>

// [[Rcpp::export]]
Rcpp::NumericVector colNorm(const RcppGSL::Matrix & G) {
    int k = G.ncol();
    Rcpp::NumericVector n(k);           // to store results
    for (int j = 0; j < k; j++) {
        RcppGSL::VectorView colview = gsl_matrix_const_column (G, j);
        n[j] = gsl_blas_dnrm2(colview);
    }
    return n;                           // return vector
}

This takes full advantage of Rcpp Attributes automagically creating the interface and exception handler (as per the previous release), adds a const & interface, does away with the tedious and error-pronce free() and uses the shorter-typedef forms for RcppGSL::Matrix and RcppGSL::VectorViews using double variables. Now the function is short and concise and hence easier to read and maintain. The package vignette has more details on using RcppGSL.

The NEWS file entries follows below:

Changes in version 0.3.0 (2015-08-30)

  • The RcppGSL matrix and vector class now keep track of object allocation and can therefore automatically free allocated object in the destructor. Explicit x.free() use is still supported.

  • The matrix and vector classes now support const reference semantics in the interfaces (thanks to PR #7 by Dan Dillon)

  • The matrix_view and vector_view classes are reorganized to better support const arguments (thanks to PR #8 and #9 by Dan Dillon)

  • Shorthand forms such as Rcpp::Matrix have been added for double and int vectors and matrices including views.

  • Examples such as fastLm can now be written in a much cleaner and shorter way as GSL objects can appear in the function signature and without requiring explicit .free() calls at the end.

  • The included examples, as well as the introductory vignette, have been updated accordingly.

Courtesy of CRANberries, a summary of changes to the most recent release is available.

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

This post by Dirk Eddelbuettel originated on his Thinking inside the box blog. Please report excessive re-aggregation in third-party for-profit settings.

/code/rcpp | permanent link

Mon, 24 Aug 2015

RcppDE 0.1.3

A pure maintenance release 0.1.3 of the RcppDE package arrived on CRAN yesterday. RcppDE is a "port" of DEoptim, a popular package for derivative-free optimisation using differential optimization, to C++. By using RcppArmadillo, the code becomes a lot shorter and more legible.

This version simply fixes a typo in the vignette metadata noticed by Kurt, and updates the package in a few other spots to update it to current CRAN Repository Policy standards.

Courtesy of CRANberries, there is also a diffstat report for the most recent release.

This post by Dirk Eddelbuettel originated on his Thinking inside the box blog. Please report excessive re-aggregation in third-party for-profit settings.

/code/rcpp | permanent link

Mon, 17 Aug 2015

RcppArmadillo 0.5.400.2.0

armadillo image

A new Armadillo release 5.400.2 was just released by Conrad. Consequently, a new RcppArmadillo release 0.5.400.2.0 went out to CRAN and into Debian.

Armadillo is a powerful and expressive C++ template library for linear algebra aiming towards a good balance between speed and ease of use with a syntax deliberately close to a Matlab.

This release contains the following extensions:

Changes in RcppArmadillo version 0.5.400.2.0 (2015-08-17)

  • Upgraded to Armadillo 5.400.2 ("Plutocracy Incorporated Deluxe")

    • added find_unique() for finding indices of unique values

    • added diff() for calculating differences between consecutive elements

    • added cumprod() for calculating cumulative product

    • added null() for finding the orthonormal basis of null space

    • expanded interp1() to handle repeated locations

    • expanded unique() to handle complex numbers

    • faster flupud()

    • faster row-wise cumsum()

    • fix for k-means clustering in gmm_diag class

  • corrected use of kitten() thanks to Grant Brown

Courtesy of CRANberries, there is also a diffstat report for the most recent CRAN 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.

This post by Dirk Eddelbuettel originated on his Thinking inside the box blog. Please report excessive re-aggregation in third-party for-profit settings.

/code/rcpp | permanent link

Tue, 04 Aug 2015

RcppArmadillo 0.5.300.4.0

armadillo image

A new Armadillo release 5.300.4 was prepared by Conrad the other day, and we prepared a new corresponding RcppArmadillo release 0.5.300.4.0 which is now on CRAN and in way into Debian.

Armadillo is a powerful and expressive C++ template library for linear algebra aiming towards a good balance between speed and ease of use with a syntax deliberately close to a Matlab.

This release brings a considerable amount of new code extending support for sparse matrices, support for Schur decompositions, and much more as shown in the extract from NEWS file:

Changes in RcppArmadillo version 0.5.300.4 (2015-08-03)

  • Upgraded to Armadillo 5.300.4 ("Plutocrazy Incorporated")

    • added generalised Schur decomposition: qz()

    • added .has_inf() and .has_nan()

    • expanded interp1() to handle out-of-domain locations

    • expanded sparse matrix class with .set_imag() and .set_real()

    • expanded imag(), real() and conj() to handle sparse matrices

    • expanded diagmat(), reshape() and resize() to handle sparse matrices

    • faster sparse sum()

    • faster row-wise sum(), mean(), min(), max()

    • updated physical constants to NIST 2014 CODATA values

    • fixes for handling sparse submatrix views

    • Armadillo can make use of GPUs by linking with NVIDIA NVBLAS (a GPU-accelerated implementation of BLAS), or by linking with AMD ACML (which can use GPUs via OpenCL)

  • Added importFrom statements for R functions not from base

  • Added explicit Rcpp::sourceCpp() reference as well

  • Updated one formatting detail in vignette to please TeXlive2015

Courtesy of CRANberries, there is also a diffstat report for the most recent CRAN 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.

This post by Dirk Eddelbuettel originated on his Thinking inside the box blog. Please report excessive re-aggregation in third-party for-profit settings.

/code/rcpp | permanent link

Sun, 26 Jul 2015

RcppZiggurat 0.1.3: Faster Random Normal Draws

ziggurats

After a slight hiatus since the last release in early 2014, we are delighted to announce a new release of RcppZiggurat which is now on the CRAN network for R.

The RcppZiggurat package updates the code for the Ziggurat generator which provides very fast draws from a Normal distribution.

The package provides a simple C++ wrapper class for the generator improving on the very basic macros, and permits comparison among several existing Ziggurat implementations. This can be seen in the figure where Ziggurat from this package dominates accessing the implementations from the GSL, QuantLib and Gretl---all of which are still way faster than the default Normal generator in R (which is of course of higher code complexity).

This release contains a few internal cleanups relative to the last release. It was triggered by a very helpful email from Brian Ripley who notices compiler warnings on the Solaris platform due to my incorrect use of on integer variables.

The NEWS file entry below lists all changes.

Changes in version 0.1.3 (2015-07-25)

  • Use the SHR3 generator for the default implementation just like Leong et al do, making our default implementation identical to theirs (but 32- and 64-bit compatible)

  • Switched generators from float to double ensuring that results are identical on 32- and 64-bit platforms

  • Simplified builds with respect to GSL use via the RcppGSL package; added a seed setter for the GSL variant

  • Corrected use of fabs() to abs() on integer variables, with a grateful nod to Brian Ripley for the hint (based on CRAN checks on the beloved Slowlaris machines)

  • Accelerated Travis CI tests by relying exclusively on r-cran-* packages from the PPAs by Michael Rutter and myself

  • Updated DESCRIPTION and NAMESPACE according to current best practices, and R-devel CMD check --as-cran checks

Courtesy of CRANberries, there is also a diffstat report for the most recent release. More information is on the RcppZiggurat page.

This post by Dirk Eddelbuettel originated on his Thinking inside the box blog. Please report excessive re-aggregation in third-party for-profit settings.

/code/rcpp | permanent link

Sat, 25 Jul 2015

Rcpp 0.12.0: Now with more Big Data!

big-data image

A new release 0.12.0 of Rcpp arrived on the CRAN network for GNU R this morning, and I also pushed a Debian package upload.

Rcpp has become the most popular way of enhancing GNU R with C++ code. As of today, 423 packages on CRAN depend on Rcpp for making analyses go faster and further. Note that this is 60 more packages since the last release in May! Also, BioConductor adds another 57 packages, and casual searches on GitHub suggests many more.

And according to Andrie De Vries, Rcpp has now page rank of one on CRAN as well!

And with this release, Rcpp also becomes ready for Big Data, or, as they call it in Texas, Data.

Thanks to a lot of work and several pull requests by Qiang Kou, support for R_xlen_t has been added.

That means we can now do stunts like

R> library(Rcpp)
R> big <- 2^31-1
R> bigM <- rep(NA, big)
R> bigM2 <- c(bigM, bigM)
R> cppFunction("double getSz(LogicalVector x) { return x.length(); }")
R> getSz(bigM)
[1] 2147483647
R> getSz(bigM2)
[1] 4294967294
R>

where prior versions of Rcpp would just have said

> getSz(bigM2)
Error in getSz(bigM2) :
  long vectors not supported yet: ../../src/include/Rinlinedfuns.h:137
>

which is clearly not Texas-style. Another wellcome change, also thanks to Qiang Kou, adds encoding support for strings.

A lot of other things got polished. We are still improving exception handling as we still get the odd curveballs in a corner cases. Matt Dziubinski corrected the var() computation to use the proper two-pass method and added better support for lambda functions in Sugar expression using sapply(), Qiang Kou added more pull requests mostly for string initialization, and Romain added a pull request which made data frame creation a little more robust, and JJ was his usual self in tirelessly looking after all aspects of Rcpp Attributes.

As always, you can follow the development via the GitHub repo and particularly the Issue tickets and Pull Requests. And any discussions, questions, ... regarding Rcpp are always welcome at the rcpp-devel mailing list.

Last but not least, we are also extremely pleased to annouce that Qiang Kou has joined us in the Rcpp-Core team. We are looking forward to a lot more awesome!

See below for a detailed list of changes extracted from the NEWS file.

Changes in Rcpp version 0.12.0 (2015-07-24)

  • Changes in Rcpp API:

    • Rcpp_eval() no longer uses R_ToplevelExec when evaluating R expressions; this should resolve errors where calling handlers (e.g. through suppressMessages()) were not properly respected.

    • All internal length variables have been changed from R_len_t to R_xlen_t to support vectors longer than 2^31-1 elements (via pull request 303 by Qiang Kou).

    • The sugar function sapply now supports lambda functions (addressing issue 213 thanks to Matt Dziubinski)

    • The var sugar function now uses a more robust two-pass method, supports complex numbers, with new unit tests added (via pull request 320 by Matt Dziubinski)

    • String constructors now allow encodings (via pull request 310 by Qiang Kou)

    • String objects are preserving the underlying SEXP objects better, and are more careful about initializations (via pull requests 322 and 329 by Qiang Kou)

    • DataFrame constructors are now a little more careful (via pull request 301 by Romain Francois)

    • For R 3.2.0 or newer, Rf_installChar() is used instead of Rf_install(CHAR()) (via pull request 332).

  • Changes in Rcpp Attributes:

    • Use more robust method of ensuring unique paths for generated shared libraries.

    • The evalCpp function now also supports the plugins argument.

    • Correctly handle signature termination characters ('{' or ';') contained in quotes.

  • Changes in Rcpp Documentation:

    • The Rcpp-FAQ vignette was once again updated with respect to OS X issues and Fortran libraries needed for e.g. RcppArmadillo.

    • The included Rcpp.bib bibtex file (which is also used by other Rcpp* packages) was updated with respect to its CRAN references.

Thanks to CRANberries, you can also look at a diff to the previous release As always, even fuller details are on the Rcpp Changelog page and the Rcpp page which also leads to the downloads page, 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.

This post by Dirk Eddelbuettel originated on his Thinking inside the box blog. Please report excessive re-aggregation in third-party for-profit settings.

/code/rcpp | permanent link

Fri, 17 Jul 2015

RcppRedis 0.1.5

Another small update to RcppRedis arrived on CRAN this morning. The fix I made a few days ago addressing a unit test setup (for the rredis package loaded only for a comparison) didn't quite work out.

Changes in version 0.1.5 (2015-07-17)

  • Another minor fix to unit test setup for rredis.

Courtesy of CRANberries, there is also a diffstat report for the most recent release. More information is on the RcppRedis page.

This post by Dirk Eddelbuettel originated on his Thinking inside the box blog. Please report excessive re-aggregation in third-party for-profit settings.

/code/rcpp | permanent link

RcppTOML 0.0.4

We introduced RcppTOML in April with the initial CRAN release 0.0.3. It permits R to read the (absolutely awesome) TOML format which is simply fabulous for configuration files.

A new version appeared on CRAN yesterday. We had observed a somewhat rare segfault in our production use which came down me dereferencing a list iterator which checking length first. Ooops.

As usual, a few other changes were made as, mostly to stay on the good side of R CMD check --as-cran for the development version of R.

Courtesy of CRANberries, there is also a diffstat report for this release More information is on the RcppRedis page.

This post by Dirk Eddelbuettel originated on his Thinking inside the box blog. Please report excessive re-aggregation in third-party for-profit settings.

/code/rcpp | permanent link

Wed, 15 Jul 2015

RcppEigen 0.3.2.5.0

A new release of RcppEigen arrived on CRAN and in Debian yesterday. It synchronizes the Eigen code with the 3.2.5 upstream release. Once again, Yixuan Qiu did most of the heavy lifting in one very nice pull request, and I added some minor updates to keep R CMD check --as-cran happy.

The NEWS file entry follows.

Changes in RcppEigen version 0.3.2.5.0 (2015-07-11)

  • Updated to version 3.2.5 of Eigen

  • Fixed some incorrect error messages stemming from Eigen code.

  • Updated package to current R CMD check standards.

Courtesy of CRANberries, there is also a diffstat report for the most recent release.

This post by Dirk Eddelbuettel originated on his Thinking inside the box blog. Please report excessive re-aggregation in third-party for-profit settings.

/code/rcpp | permanent link

Mon, 13 Jul 2015

RcppGSL 0.2.5

A new version of RcppGSL arrived on CRAN a couple of days ago. This package provides an interface from R to the GNU GSL using our Rcpp package.

In the course of preparation for the higher-performance R via C++ course I gave in Zuerich last month, I overhauled this package, its embedded package (!!) showing how to build a package which uses R, C++ and the GSL (and which can serve as a fine example of how to build and R and C++ package using an external library), and also overhauled the vignette which discusses all these aspect. All examples now consistently use Rcpp Attributes.

The NEWS file entries follows below:

Changes in version 0.2.5 (2015-07-05)

  • The colnorm function in the included example package was rewritten to use Rcpp Attributes, the example package was updated and its version number increased to 0.0.3.

  • The unit tests also use the updated version of the example package.

  • The package, and the included example package, were updated throughout to conform to the current R CMD check standards.

  • The RcppGSL-intro vignette was updated throughout.

  • The Travis CI integration now uses r-cran-* packages which leads to faster tests.

Courtesy of CRANberries, a summary of changes to the most recent release is available.

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

This post by Dirk Eddelbuettel originated on his Thinking inside the box blog. Please report excessive re-aggregation in third-party for-profit settings.

/code/rcpp | permanent link

Sun, 12 Jul 2015

RcppRedis 0.1.4

A small update to RcppRedis arrived on CRAN a few days ago. One of the unit tests failed as we (still) initialized the rredis package (loaded only for a comparison) in a form long-internalized by Bryan Lewis, its author. No actual changes to functionality were; the only other changes is cosmetic and in response a R CMD check requirement where the curl binary seemingly fails to follow redirects so we removed the (official !) redis.io URL.

Changes in version 0.1.4 (2015-07-04)

  • Minor update to unit test setup for rredis.

  • No longer list URLs to Redis as automated CRAN tests for URL validity choke on redirects.

Courtesy of CRANberries, there is also a diffstat report for the most recent release. More information is on the RcppRedis page.

This post by Dirk Eddelbuettel originated on his Thinking inside the box blog. Please report excessive re-aggregation in third-party for-profit settings.

/code/rcpp | permanent link

Fri, 05 Jun 2015

RcppArmadillo 0.5.200.1.0

Conrad put out a new minor release 5.200.1 of Armadillo yesterday. Armadillo is a powerful and expressive C++ template library for linear algebra aiming towards a good balance between speed and ease of use with a syntax deliberately close to a Matlab.

Our corresponding RcppArmadillo release 0.5.200.1.0 is now on CRAN and on its way into Debian. See below for the brief list of changes.

Changes in RcppArmadillo version 0.5.200.1.0 (2015-06-04)

  • Upgraded to Armadillo release 5.200.1 ("Boston Tea Smuggler")

    • added orth() for finding the orthonormal basis of the range space of a matrix

    • expanded element initialisation to handle nested initialiser lists (C++11)

    • workarounds for bugs in GCC, Intel and MSVC C++ compilers

  • Added another example to inst/examples/fastLm.r

Courtesy of CRANberries, there is also a diffstat report for the most recent CRAN 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.

This post by Dirk Eddelbuettel originated on his Thinking inside the box blog. Please report excessive re-aggregation in third-party for-profit settings.

/code/rcpp | permanent link

Mon, 04 May 2015

RcppAnnoy 0.0.6

annoy logo

A few days ago, Erik released a new version of his Annoy library -- a small, fast, and lightweight C++ template header library for approximate nearest neighbours -- which now no longer requires Boost. While I don't mind Boost (actually, quite the opposite), it appears to have been a blocker in getting the Python part of Annoy over to the world of python3.

And with a new Annoy out, I updated RcppAnnoy to it. In the process I got another pull request into Annoy (use R's RNG rather than rand() which R CMD check really dislikes).

This new package is now on CRAN.

Courtesy of CRANberries, there is also a diffstat report for this release.

More detailed information is on the RcppAnnoy page page.

This post by Dirk Eddelbuettel originated on his Thinking inside the box blog. Please report excessive re-aggregation in third-party for-profit settings.

/code/rcpp | permanent link

Sat, 02 May 2015

Rcpp 0.11.6

The new release 0.11.5 of Rcpp arrived on the CRAN network for GNU R yesterday; the corresponding Debian package has also been uploaded.

Rcpp has become the most popular way of enhancing GNU R with C++ code. As of today, 373 packages on CRAN depend on Rcpp for making analyses go faster and further; BioConductor adds another 57 packages, and casual searches on GitHub suggests many more.

This version adds a little more polish and refinement around things we worked on previous releases to solidify builds, installation and the run-time experience. It does not bring anything new or majorrelease continues the 0.11.* release cycle, adding another large number of small bug fixes, polishes and enhancements. As always, you can follow the development via the GitHub repo and particularly the Issue tickets and Pull Requests. And any discussions, questions, ... regarding Rcpp are always welcome at the rcpp-devel mailing list.

See below for a detailed list of changes extracted from the NEWS file.

Changes in Rcpp version 0.11.6 (2015-05-01)

  • Changes in Rcpp API:

    • The unwinding of exceptions was refined to protect against inadvertent memory leaks.

    • Header files now try even harder not to let macro definitions leak.

    • Matrices have a new default constructor for zero-by-zero dimension matrices (via a pull request by Dmitrii Meleshko).

    • A new empty() string constructor was added (via another pull request).

    • Better support for Vectors with a storage policy different from the default, i.e. NoProtectStorage, was added.

  • Changes in Rcpp Attributes:

    • Rtools 3.3 is now supported.

Thanks to CRANberries, you can also look at a diff to the previous release As always, even fuller details are on the Rcpp Changelog page and the Rcpp page which also leads to the downloads page, 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.

This post by Dirk Eddelbuettel originated on his Thinking inside the box blog. Please report excessive re-aggregation in third-party for-profit settings.

/code/rcpp | permanent link

RcppArmadillo 0.5.100.1.0

A new minor release 5.100.1 of Armadillo was released by Conrad yesterday. Armadillo is a powerful and expressive C++ template library for linear algebra aiming towards a good balance between speed and ease of use with a syntax deliberately close to a Matlab.

Our corresponding RcppArmadillo release 0.5.100.1.0 also reached CRAN and Debian yesterday. See below for the brief list of changes.

Changes in RcppArmadillo version 0.5.100.1.0 (2015-05-01)

  • Upgraded to Armadillo release 5.100.1 ("Ankle Biter Deluxe")

    • added interp1() for 1D interpolation

    • added .is_sorted() for checking whether a vector or matrix has sorted elements

    • updated physical constants to NIST 2010 CODATA values

Courtesy of CRANberries, there is also a diffstat report for the most recent CRAN 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.

This post by Dirk Eddelbuettel originated on his Thinking inside the box blog. Please report excessive re-aggregation in third-party for-profit settings.

/code/rcpp | permanent link

Tue, 28 Apr 2015

RcppTOML 0.0.3: A New Approach to Configuration Files

A small project I worked on during the last few weeks has now come together in new package RcppTOML which arrived on CRAN yesterday.

It provides R with a reader for TOML files. TOML stands for Tom's Obvious Markup Language. And before you roll your eyes, glance at the TOML site. It really is different, and has a number of rather wonderful features:

  • free-format indentation as you please
  • comments anywhere, even on the same line
  • actual types such as string, integer, float, bool and datetime (!!) which are all native
  • vectors, of course, of the above
  • arbitrary nesting of tables

Here is a simple illustration where we parse the TOML example file derived from what is part of the main TOML README

R> p <- parseTOML(system.file("toml", "example.toml", package="RcppTOML"))
R> summary(p)
toml object with top-level slots:
   clients, database, owner, servers, title 
read from /usr/local/lib/R/site-library/RcppTOML/toml/example.toml 
R> p
List of 5
 $ clients :List of 2
  ..$ data :List of 2
  .. ..$ : chr [1:2] "gamma" "delta"
  .. ..$ : int [1:2] 1 2
  ..$ hosts: chr [1:2] "alpha" "omega"
 $ database:List of 4
  ..$ connection_max: int 5000
  ..$ enabled       : logi TRUE
  ..$ ports         : int [1:3] 8001 8001 8002
  ..$ server        : chr "192.168.1.1"
 $ owner   :List of 4
  ..$ bio         : chr "GitHub Cofounder & CEO\\nLikes tater tots and beer."
  ..$ dob         : POSIXct[1:1], format: "1979-05-27 07:32:00"
  ..$ name        : chr "Tom Preston-Werner"
  ..$ organization: chr "GitHub"
 $ servers :List of 2
  ..$ alpha:List of 2
  .. ..$ dc: chr "eqdc10"
  .. ..$ ip: chr "10.0.0.1"
  ..$ beta :List of 2
  .. ..$ dc: chr "eqdc10"
  .. ..$ ip: chr "10.0.0.2"
 $ title   : chr "TOML Example"
NULL
R> 

See much more at the TOML site. I converted one first project at work to this and it really rocks. Point to a file, get a list back and index all components by their names.

We also added really simple S3 classes to the default print() method uses str() for a more compact presentation of what (in R) is of course nested list types.

Internally, the RcppTOML packages use the splendid cpptoml parser by Chase Geigle. This brings in modern C++11 and makes it that CRAN simply cannot build a binary for R on Windows as the g++ version (still, as of April 2015) in Rtools is too old. There is word of an update to Rtools and that point should we able to support Windows as well. Until then, no mas.

A bit more information is on the package page here as well as as the GitHub repo.

This post by Dirk Eddelbuettel originated on his Thinking inside the box blog. Please report excessive re-aggregation in third-party for-profit settings.

/code/rcpp | permanent link

Wed, 22 Apr 2015

RcppArmadillo 0.5.000.0

A new major version 5.000 of Armadillo was released by Conrad a couple of days ago. Armadillo is a powerful and expressive C++ template library for linear algebra aiming towards a good balance between speed and ease of use with a syntax deliberately close to a Matlab.

This version brings several new functions for sparse matrices, and automagically switches to 64-bit matrix indices in C++11 mode. See below for a short description of all the major changes based on the NEWS.Rd file.

This version is now on CRAN, as well as in Debian. The integration into CRAN was delayed by a few days as my testing had a shortcoming. We run full reverse-dependency checks against all 115 CRAN package depending in RcppArmadillo, and we even made full pre-release 0.4.999.1 and 0.5.000.0 shipped to the drat repo of the RcppCore GitHub organization (which was described in the previous release post). But a minor flaw in my setup made it miss how the change in indexing affected packages dfcomb and dfmta. My thanks to its maintainer Marie-Karelle Riviere for providing updates to her packages permitting this release to get onto CRAN. The testing process has been tightened and this should not happen again.

Changes in RcppArmadillo version 0.5.000.0 (2015-04-12)

  • Upgraded to Armadillo release Version 5.000 ("Ankle Biter")

    • added spsolve() for solving sparse systems of linear equations

    • added svds() for singular value decomposition of sparse matrices

    • added nonzeros() for extracting non-zero values from matrices

    • added handling of diagonal views by sparse matrices

    • expanded repmat() to handle sparse matrices

    • expanded join_rows() and join_cols() to handle sparse matrices

    • sort_index() and stable_sort_index() have been placed in the delayed operations framework for increased efficiency

    • use of 64 bit integers is automatically enabled when using a C++11 compiler

    • workaround for a bug in recent releases of Apple Xcode

    • workaround for a bug in LAPACK 3.5

Changes in RcppArmadillo version 0.4.999.1.0 (2015-04-04)

  • Upgraded to Armadillo release preview 4.999.1

  • Non-CRAN test release

Courtesy of CRANberries, there is also a diffstat report for the most recent CRAN 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.

This post by Dirk Eddelbuettel originated on his Thinking inside the box blog. Please report excessive re-aggregation in third-party for-profit settings.

/code/rcpp | permanent link

Fri, 06 Mar 2015

Rcpp 0.11.5

The new release 0.11.5 of Rcpp just reached the CRAN network for GNU R, and a Debian package has also been be uploaded.

Rcpp has become the most popular way of enhancing GNU R with C++ code. As of today, 345 packages on CRAN depend on Rcpp for making analyses go faster and further; BioConductor adds another 41 packages, and casual searches on GitHub suggests dozens mores.

This release continues the 0.11.* release cycle, adding another large number of small bug fixes, polishes and enhancements. Since the previous release in January, we incorporated a number of pull requests and changes from several contributors. This time, JJ deserves a special mention as he is responsible for a metric ton of the changes listed below, making Rcpp Attributes even more awesome. As always, you can follow the development via the GitHub repo and particularly the Issue tickets and Pull Requests. And any discussions, questions, ... regarding Rcpp are always welcome at the rcpp-devel mailing list.

See below for a detailed list of changes extracted from the NEWS file.

Changes in Rcpp version 0.11.5 (2015-03-04)

  • Changes in Rcpp API:

    • An error handler for tinyformat was defined to prevent the assert() macro from spilling.

    • The Rcpp::warning function was added as a wrapper for Rf_warning.

    • The XPtr class was extended with new checked_get and release functions as well as improved behavior (throw an exception rather than crash) when a NULL external pointer is dereferenced.

    • R code is evaluated within an R_toplevelExec block to prevent user interrupts from bypassing C++ destructors on the stack.

    • The Rcpp::Environment constructor can now use a supplied parent environment.

    • The Rcpp::Function constructor can now use a supplied environment or namespace.

    • The attributes_hidden macro from R is used to shield internal functions; the R_ext/Visibility.h header is now included as well.

    • A Rcpp::print function was added as a wrapper around Rf_PrintValue.

  • Changes in Rcpp Attributes:

    • The pkg_types.h file is now included in RcppExports.cpp if it is present in either the inst/include or src.

    • sourceCpp was modified to allow includes of local files (e.g. #include "foo.hpp"). Implementation files (.cc; .cpp) corresponding to local includes are also automatically built if they exist.

    • The generated attributes code was simplified with respect to RNGScope and now uses RObject and its destructor rather than SEXP protect/unprotect.

    • Support addition of the rng parameter in Rcpp::export to suppress the otherwise automatic inclusion of RNGScope in generated code.

    • Attributes code was made more robust and can e.g. no longer recurse.

    • Version 3.2 of the Rtools is now correctly detected as well.

    • Allow 'R' to come immediately after '***' for defining embedded R code chunks in sourceCpp.

    • The attributes vignette has been updated with documentation on new features added over the past several releases.

  • Changes in Rcpp tests:

    • On Travis CI, all build dependencies are installed as binary .deb packages resulting in faster tests.

  • Thanks to CRANberries, you can also look at a diff to the previous release As always, even fuller details are on the Rcpp Changelog page and the Rcpp page which also leads to the downloads page, 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.

    This post by Dirk Eddelbuettel originated on his Thinking inside the box blog. Please report excessive re-aggregation in third-party for-profit settings.

    /code/rcpp | permanent link

    Sat, 28 Feb 2015

    RcppEigen 0.3.2.4.0

    A new release of RcppEigen is now on CRAN and in Debian. It synchronizes the Eigen code with the 3.2.4 upstream release, and updates the RcppEigen.package.skeleton() package creation helper to use the kitten() function from pkgKitten for enhanced package creation.

    The NEWS file entry follows.

    Changes in RcppEigen version 0.3.2.4.0 (2015-02-23)

    • Updated to version 3.2.4 of Eigen

    • Update RcppEigen.package.skeleton() to use pkgKitten if available

    Courtesy of CRANberries, there is also a diffstat report for the most recent release.

    This post by Dirk Eddelbuettel originated on his Thinking inside the box blog. Please report excessive re-aggregation in third-party for-profit settings.

    /code/rcpp | permanent link

    Thu, 26 Feb 2015

    RcppArmadillo 0.4.650.1.1 (and also 0.4.650.2.0)

    A new Armadillo release 4.650.1 was released by Conrad a few days ago. Armadillo is a powerful and expressive C++ template library for linear algebra aiming towards a good balance between speed and ease of use with a syntax deliberately close to a Matlab.

    It turned out that this release had one shortcoming with respect to the C++11 RNG initializations in the R use case (where we need to protect the users from the C++98 RNG deemed unsuitable by the CRAN gatekeepers). And this lead to upstream release 4.650.1 which we wrapped into RcppArmadillo 0.4.650.1.1. As before this, was tested against all 107 reverse dependencies of RcppArmadillo on the CRAN repo.

    This version is now on CRAN, and was just uploaded to Debian. Its changes are summarized below based on the NEWS.Rd file.

    Changes in RcppArmadillo version 0.4.650.1.1 (2015-02-25)

    • Upgraded to Armadillo release Version 4.650.1 ("Intravenous Caffeine Injector")

      • added randg() for generating random values from gamma distributions (C++11 only)

      • added .head_rows() and .tail_rows() to submatrix views

      • added .head_cols() and .tail_cols() to submatrix views

      • expanded eigs_sym() to optionally calculate eigenvalues with smallest/largest algebraic values fixes for handling of sparse matrices

    • Applied small correction to main header file to set up C++11 RNG whether or not the alternate RNG (based on R, our default) is used

    Now, it turns out that another small fix was needed for the corner case of a submatrix within a submatrix, ie V.subvec(1,10).tail(5). I decided not to re-release this to CRAN given the CRAN Repository Policy preference for releases “no more than every 1–2 months”.

    But fear not, for we now have drat. I created a drat package repository in the RcppCore account (to not put a larger package into my main drat repository often used via a fork to initialize a drat). So now with these two simple commands

    ## if needed, first install 'drat' via:   install.packages("drat")
    drat:::add("RcppCore")
    update.packages()

    you will get the newest RcppArmadillo via this drat package repository. And course install.packages("RcppArmadillo") would also work, but takes longer to type :)

    Lastly, courtesy of CRANberries, there is also a diffstat report for the most recent CRAN 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.

    This post by Dirk Eddelbuettel originated on his Thinking inside the box blog. Please report excessive re-aggregation in third-party for-profit settings.

    /code/rcpp | permanent link

    Sat, 21 Feb 2015

    RcppAPT 0.0.1

    Over the last few days I put together a new package RcppAPT which interfaces the C++ library behind the awesome apt, apt-get, apt-cache, ... commands and their GUI-based brethren.

    The package currently implements two functions which permit search for package information via a regular expression, as well as a (vectorised) package name-based check. More to come, and contributions would be very welcome.

    A few examples just to illustrate follow.

    R> hasPackages(c("r-cran-rcpp", "r-cran-rcppapt"))
       r-cran-rcpp r-cran-rcppapt 
              TRUE          FALSE 

    This shows that Rcpp is (of course) available as a binary, but this (very new) package is (unsurprisingly) not yet available pre-built.

    We can search by regular expression:

    R> library(RcppAPT)
    R> getPackages("^r-base-c.")
              Package      Installed       Section
    1 r-base-core-dbg 3.1.2-1utopic0 universe/math
    2 r-base-core-dbg           <NA> universe/math
    3     r-base-core 3.1.2-1utopic0 universe/math
    4     r-base-core           <NA> universe/math
    R> 

    With the (default) expression catching everything, we see a lot of packages:

    R> dim(getPackages())
    [1] 104431      3
    R> 

    A bit more information is on the package page here as well as as the GitHub repo.

    This post by Dirk Eddelbuettel originated on his Thinking inside the box blog. Please report excessive re-aggregation in third-party for-profit settings.

    /code/rcpp | permanent link

    Mon, 02 Feb 2015

    RcppStreams 0.1.0

    Streamulus

    The new package RcppStreams arrived on CRAN on Saturday. RcppStreams brings the excellent Streamulus C++ template library for event stream processing to R.

    Streamulus, written by Irit Katriel, uses very clever template meta-programming (via Boost Fusion) to implement an embedded domain-specific event language created specifically for event stream processing.

    The packages wraps the four existing examples by Irit, all her unit tests and includes a slide deck from a workshop presentation. The framework is quite powerful, and it brings a very promising avenue for (efficient !!) stream event processing to R.

    The NEWS file entries follows below:

    Changes in version 0.1.0 (2015-01-30)

    • First CRAN release

    • Contains all upstream examples and documentation from Streamulus

    • Added Rcpp Attributes wrapping and minimal manual pages

    • Added Travis CI unit testing

    Courtesy of CRANberries, there is also a copy of the DESCRIPTION file for this initial release. More detailed information is on the RcppStreams page page and of course on the Streamulus page.

    This post by Dirk Eddelbuettel originated on his Thinking inside the box blog. Please report excessive re-aggregation in third-party for-profit settings.

    /code/rcpp | permanent link

    Sun, 25 Jan 2015

    RcppArmadillo 0.4.600.4.0

    Conrad put up a maintenance release 4.600.4 of Armadillo a few days ago. As in the past, we tested this with number of pre-releases and test builds against the now over one hundred CRAN dependents of our RcppArmadillo package. The tests passed fine as usual, and results are as always in the rcpp-logs repository.

    Changes are summarized below based on the NEWS.Rd file.

    Changes in RcppArmadillo version 0.4.600.4.0 (2015-01-23)

    • Upgraded to Armadillo release Version 4.600.4 (still "Off The Reservation")

      • Speedups in the transpose operation

      • Small bug fixes

    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.

    This post by Dirk Eddelbuettel originated on his Thinking inside the box blog. Please report excessive re-aggregation in third-party for-profit settings.

    /code/rcpp | permanent link

    Sat, 24 Jan 2015

    Rcpp 0.11.4

    A new release 0.11.4 of Rcpp is now on the CRAN network for GNU R, and an updated Debian package will be uploaded in due course.

    Rcpp has become the most popular way of enhancing GNU R with C++ code. As of today, 323 packages on CRAN depend on Rcpp for making analyses go faster and further; BioConductor adds another 41 packages, and casual searches on GitHub suggests dozens mores.

    This release once again adds a large number of small bug fixes, polishes and enhancements. And like the last time, these changes were made by a group of seven different contributors (counting code commits) plus three more providing concrete suggestions. This shows that the Rcpp development and maintenance rests a large number of (broad) shoulders.

    See below for a detailed list of changes extracted from the NEWS file.

    Changes in Rcpp version 0.11.4 (2015-01-20)

    • Changes in Rcpp API:

      • The ListOf<T> class gains the .attr and .names methods common to other Rcpp vectors.

      • The [dpq]nbinom_mu() scalar functions are now available via the R:: namespace when R 3.1.2 or newer is used.

      • Add an additional test for AIX before attempting to include execinfo.h.

      • Rcpp::stop now supports improved printf-like syntax using the small tinyformat header-only library (following a similar implementation in Rcpp11)

      • Pairlist objects are now protected via an additional Shield<> as suggested by Martin Morgan on the rcpp-devel list.

      • Sorting is now prohibited at compile time for objects of type List, RawVector and ExpressionVector.

      • Vectors now have a Vector::const_iterator that is 'const correct' thanks to fix by Romain following a bug report in rcpp-devel by Martyn Plummer.

      • The mean() sugar function now uses a more robust two-pass method, and new unit tests for mean() were added at the same time.

      • The mean() and var() functions now support all core vector types.

      • The setequal() sugar function has been corrected via suggestion by Qiang Kou following a bug report by Søren Højsgaard.

      • The macros major, minor, and makedev no longer leak in from the (Linux) system header sys/sysmacros.h.

      • The push_front() string function was corrected.

    • Changes in Rcpp Attributes:

      • Only look for plugins in the package's namespace (rather than entire search path).

      • Also scan header files for definitions of functions to be considerd by Attributes.

      • Correct the regular expression for source files which are scanned.

    • Changes in Rcpp unit tests

      • Added a new binary test which will load a pre-built package to ensure that the Application Binary Interface (ABI) did not change; this test will (mostly or) only run at Travis where we have reasonable control over the platform running the test and can provide a binary.

      • New unit tests for sugar functions mean, setequal and var were added as noted above.

    • Changes in Rcpp Examples:

      • For the (old) examples ConvolveBenchmarks and OpenMP, the respective Makefile was renamed to GNUmakefile to please R CMD check as well as the CRAN Maintainers.

    Thanks to CRANberries, you can also look at a diff to the previous release As always, even fuller details are on the Rcpp Changelog page and the Rcpp page which also leads to the downloads page, 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.

    This post by Dirk Eddelbuettel originated on his Thinking inside the box blog. Please report excessive re-aggregation in third-party for-profit settings.

    /code/rcpp | permanent link

    RcppGSL 0.2.4

    A new version of RcppGSL is now on CRAN. This package provides an interface from R to the GNU GSL using our Rcpp package.

    This follows on the heels on the recent RcppGSL 0.2.3 release and extends the excellent point made by Qiang Kou in a contributed section of the vignette: We now not only allow to turn the GSL error handler off (to not abort() on error) but do so on package initialisation.

    No other user-facing changes were made.

    The NEWS file entries follows below:

    Changes in version 0.2.4 (2015-01-24)

    • Two new helper function to turn the default GSL error handler off (and to restore it) were added. The default handler is now turned off when the package is attached so that GSL will no longer abort an R session on error. Users will have to check the error code.

    • The RcppGSL-intro.Rnw vignette was expanded with a short section on the GSL error handler (thanks to Qiang Kou).

    Courtesy of CRANberries, a summary of changes to the most recent release is available.

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

    This post by Dirk Eddelbuettel originated on his Thinking inside the box blog. Please report excessive re-aggregation in third-party for-profit settings.

    /code/rcpp | permanent link

    RcppAnnoy 0.0.5

    A new version of RcppAnnoy is now on CRAN. RcppAnnoy wraps the small, fast, and lightweight C++ template header library Annoy written by Erik Bernhardsson for use at Spotify. RcppAnnoy uses Rcpp Modules to offer the exact same functionality as the Python module wrapped around Annoy.

    This version contains a trivial one-character change requested by CRAN to cleanse the Makevars file of possible GNU Make-isms. Oh well. This release also overcomes an undefined behaviour sanitizer bug noticed by CRAN that took somewhat more effort to deal with. As mentioned recently in another blog post, it took some work to create a proper Docker container with the required compiler and subsequent R setup, but we have one now, and the aforementioned blog post has details on how we replicated the CRAN finding of an UBSAN issue. It also took Erik some extra efforts to set something up for his C++/Python side, but eventually an EC2 instance with Ubuntu 14.10 did the task as my Docker sales skills are seemingly not convincing enough. In any event, he very quickly added the right fix, and I synced RcppAnnoy with his Annoy code.

    Courtesy of CRANberries, there is also a diffstat report for this release. More detailed information is on the RcppAnnoy page page.

    This post by Dirk Eddelbuettel originated on his Thinking inside the box blog. Please report excessive re-aggregation in third-party for-profit settings.

    /code/rcpp | permanent link

    Mon, 12 Jan 2015

    RcppGSL 0.2.3

    A new version of RcppGSL is now on CRAN today. This package provides an interface from R to the GNU GSL using our Rcpp.

    Similar to the recent RcppClassic release, this update was triggered by the CRAN maintainers desire to keep the Makefile free of GNU make extensions. At the same time we simplified the configure file a little, and refreshed the look and feel of the vignette.

    No user-facing changes were made.

    The NEWS file entries follows below:

    Changes in version 0.2.3 (2015-01-10)

    • The src/Makevars.in was pruned of GNU make features at the request of the CRAN Maintainers

    • configure.ac and configure were updated, and shortened

    • The RcppGSL-intro.Rnw vignette was updated for its look and feel.

    Courtesy of CRANberries, a summary of changes to the most recent release is available.

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

    This post by Dirk Eddelbuettel originated on his Thinking inside the box blog. Please report excessive re-aggregation in third-party for-profit settings.

    /code/rcpp | permanent link

    Sat, 10 Jan 2015

    RcppClassic 0.9.6

    A maintenance release of RcppClassic, now at version 0.9.6, went out to CRAN today. This package provides a maintained version of the otherwise deprecated first Rcpp API; no new projects should use it.

    No changes were in user-facing code. The Makevars file was change to accomodate a request by the CRAN Maintainer to keep it free of GNU Make extensions. At the same time, we overhauled the look and feel of the (very short) vignette. Build instructions were updated both in the vignette and in the included example package. Other accumulated changes since the last release were updates to the DESCRIPTION and NAMESPACE file as well two namespace-related R code updates.

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

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

    This post by Dirk Eddelbuettel originated on his Thinking inside the box blog. Please report excessive re-aggregation in third-party for-profit settings.

    /code/rcpp | permanent link

    Tue, 06 Jan 2015

    RcppCNPy 0.2.4

    A new release of the RcppCNPy package is now on CRAN.

    This release mostly solidifies and fixes things. Support for saving integer objects, which was expanded in release 0.2.3, was not entirely correct. Operations on big-endian systems were not up to snuff either.

    Wush Wu helped in getting this right with very diligent testing and patching particularly on big-endian hardware. We also got a pull request from Romain to reflect better const correctness at the Rcpp side of things. Last but not least we obliged by the CRAN Maintainers to not assume one could call gzip from system() call because, well, you guessed it.

    Changes in version 0.2.4 (2015-01-05)

    • Support for saving integer objects was not correct and has been fixed.

    • Support for loading and saving on 'big endian' systems was incomplete, has been greatly expanded and corrected, thanks in large part to very diligent testing as well as patching by Wush Wu.

    • The implementation now uses const iterators, thanks to a pull request by Romain Francois.

    • The vignette no longer assumes that one can call gzip via system as the world's leading consumer OS may disagree.

    CRANberries also provides a diffstat report for the latest release. As always, feedback is welcome and the rcpp-devel mailing list off the R-Forge page for Rcpp is may be the best place to start a discussion. GitHub issue tickets are also welcome.

    This post by Dirk Eddelbuettel originated on his Thinking inside the box blog. Please report excessive re-aggregation in third-party for-profit settings.

    /code/rcpp | permanent link

    Sun, 28 Dec 2014

    RcppArmadillo 0.4.600.0

    Conrad produced another minor release 4.600 of Armadillo. As before, I had created a GitHub-only pre-release(s) of his pre-release(s), and tested a pre-release as well as the actual release against the now over one hundred CRAN dependents of our RcppArmadillo package. The tests passed fine as usual with less than a handful of checks not passing, all for known cases -- and results are as always in the rcpp-logs repository.

    Changes are summarized below based on the NEWS.Rd file.

    Changes in RcppArmadillo version 0.4.600.0 (2014-12-27)

    • Upgraded to Armadillo release Version 4.600 ("Off The Reservation")

      • added .head() and .tail() to submatrix views

      • faster matrix transposes within compound expressions

      • faster accu() and norm() when compiling with -O3 -ffast-math -march=native (gcc and clang)

      • workaround for a bug in GCC 4.4

    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.

    This post by Dirk Eddelbuettel originated on his Thinking inside the box blog. Please report excessive re-aggregation in third-party for-profit settings.

    /code/rcpp | permanent link

    Tue, 23 Dec 2014

    RcppEigen 0.3.2.3.0

    A new release of RcppEigen is now on CRAN, and will get to Debian shortly.

    This is thanks to a fabulous pull request by Yixuan Qiu who single-handedly managed to upgrade to the new minor release of Eigen -- after having expanded the unit tests a few weeks earlier in another pull request.

    The NEWS file entry follows.

    Changes in RcppEigen version 0.3.2.3.0 (2014-12-22)

    • Updated to version 3.2.3 of Eigen

    • Added a number of additional unit tests for wrap, transform and sparse

    • Updated one of the examples

    Courtesy of CRANberries, there is also a diffstat report for the most recent release.

    This post by Dirk Eddelbuettel originated on his Thinking inside the box blog. Please report excessive re-aggregation in third-party for-profit settings.

    /code/rcpp | permanent link

    Wed, 10 Dec 2014

    RcppRedis 0.1.3

    A very minor bugfix release of RcppRedis is now on CRAN. The zcount function now returns the correct type.

    Changes in version 0.1.3 (2014-12-10)

    • Bug fix setting correct return type of zcount

    Courtesy of CRANberries, there is also a diffstat report for the most recent release. More information is on the RcppRedis page.

    This post by Dirk Eddelbuettel originated on his Thinking inside the box blog. Please report excessive re-aggregation in third-party for-profit settings.

    /code/rcpp | permanent link

    Tue, 09 Dec 2014

    RcppAnnoy 0.0.4

    A few weeks ago, RcppAnnoy had its initial release 0.0.2 and subsequent update in release 0.0.3. The latter brought Windows support, thanks to a neat pull request by Qiang Kou.

    RcppAnnoy wraps the small, fast, and lightweight C++ template header library Annoy written by Erik Bernhardsson for use at Spotify. RcppAnnoy uses Rcpp Modules to offer the exact same functionality as the Python module wrapped around Annoy.

    In the 0.0.3 release, I overlooked one thing: that with builds on Windows, we would also get builds against what CRAN calls R-oldrel: the previous release, which cannot turn on C++11 via the simple CXX_STD = CXX11 declaration in src/Makevars (and which we need because use of Boost brings in long long which R can only cope with under C++11 ...).

    So this new release 0.0.4 does nothing more than add a constraint in a Depends: R (>= 3.1.0) to avoid builds not being able to turn on C++11.

    Courtesy of CRANberries, there is also a diffstat report for this release. More detailed information is on the RcppAnnoy page page.

    This post by Dirk Eddelbuettel originated on his Thinking inside the box blog. Please report excessive re-aggregation in third-party for-profit settings.

    /code/rcpp | permanent link

    Sat, 29 Nov 2014

    RcppArmadillo 0.4.550.1.0

    A week ago, Conrad provided another minor release 4.550.0 of Armadillo which has since received one minor correction in 4.550.1.0. As before, I had created a GitHub-only pre-release of his pre-release which was tested against the almost one hundred CRAN dependents of our RcppArmadillo package. This passed fine as usual, and results are as always in the rcpp-logs repository.

    Processing and acceptance at the CRAN took a little longer as around the same time a fresh failure in unit tests had become apparent on an as-of-yet unannounced new architecture (!!) also tested at CRAN. The R-devel release has since gotten a new capabilities() test for long double, and we now only run this test (for our rmultinom()) if the test asserts that the given R build has this capability. Phew, so with all that the new version in now on CRAN; Windows binaries have been built and I also uploaded new Debian binaries.

    Changes are summarized below; our end also includes added support for conversion of Field types takes to short pull request by Romain.

    Changes in RcppArmadillo version 0.4.550.1.0 (2014-11-26)

    • Upgraded to Armadillo release Version 4.550.1 ("Singapore Sling Deluxe")

      • added matrix exponential function: expmat()

      • faster .log_p() and .avg_log_p() functions in the gmm_diag class when compiling with OpenMP enabled

      • faster handling of in-place addition/subtraction of expressions with an outer product

      • applied correction to gmm_diag relative to the 4.550 release

    • The Armadillo Field type is now converted in as<> conversions

    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.

    This post by Dirk Eddelbuettel originated on his Thinking inside the box blog. Please report excessive re-aggregation in third-party for-profit settings.

    /code/rcpp | permanent link

    Tue, 25 Nov 2014

    Rcpp now used by 300 CRAN packages

    max-heap image

    This morning, Rcpp reached another round milestone: 300 packages on CRAN now depend on it (as measured by Depends, Imports and LinkingTo declarations). The graph is on the left depicts the growth of Rcpp usage over time. There are 41 more on BioConductor (which is not included in the chart).

    The first and less detailed part uses manually save entries, the second half of the data set was generated semi-automatically via a short script appending updates to a small file-based backend. A list of user package is kept on this page.

    Also displayed in the graph is the relative proportion of CRAN packages using Rcpp. The four per-cent hurdle was cleared just before useR! 2014 where I showed a similar graph (as two distinct graphs) in my invited talk. We may well hit five per-cent before the end of the year.

    300 is a pretty humbling and staggering number. Also interesting that we we cleared 200 only at the end of April, and 250 in early August.

    So from everybody behind Rcpp, a heartfelt Thank You! to all the users and of course other contributors.

    This post by Dirk Eddelbuettel originated on his Thinking inside the box blog. Please report excessive re-aggregation in third-party for-profit settings.

    /code/rcpp | permanent link

    Tue, 18 Nov 2014

    RcppAnnoy 0.0.3

    Hours after the initial blog post announcing the first release of the new package RcppAnnoy, Qiang Kou sent us a very nice pull request adding mmap support in Windows.

    So a new release with Windows support is on now CRAN, and Windows binaries should be available by this evening as usual.

    To recap, RcppAnnoy wraps the small, fast, and lightweight C++ template header library Annoy written by Erik Bernhardsson for use at Spotify. RcppAnnoy uses Rcpp Modules to offer the exact same functionality as the Python module wrapped around Annoy.

    Courtesy of CRANberries, there is also a diffstat report for this release. More detailed information is on the RcppAnnoy page page.

    This post by Dirk Eddelbuettel originated on his Thinking inside the box blog. Please report excessive re-aggregation in third-party for-profit settings.

    /code/rcpp | permanent link

    Sun, 16 Nov 2014

    Introducing RcppAnnoy

    A new package RcppAnnoy is now on CRAN.

    It wraps the small, fast, and lightweight C++ template header library Annoy written by Erik Bernhardsson for use at Spotify.

    While Annoy is setup for use by Python, RcppAnnoy offers the exact same functionality from R via Rcpp.

    A new page for RcppAnnoy provides some more detail, example code and further links. See a recent blog post by Erik for a performance comparison of different approximate nearest neighbours libraries for Python.

    This post by Dirk Eddelbuettel originated on his Thinking inside the box blog. Please report excessive re-aggregation in third-party for-profit settings.

    /code/rcpp | permanent link

    Thu, 06 Nov 2014

    RcppRedis 0.1.2

    A new release of RcppRedis is now on CRAN. It contains additional commands for hashes and sets, all contributed by John Laing and Whit Armstrong.

    Changes in version 0.1.2 (2014-11-06)

    • New commands execv, hset, hget, sadd, srem, and smembers contributed by John Laing and Whit Armstrong over several pull requests.

    Courtesy of CRANberries, there is also a diffstat report for the most recent release. As always, more detailed information is on the RcppRedis page page.

    This post by Dirk Eddelbuettel originated on his Thinking inside the box blog. Please report excessive re-aggregation in third-party for-profit settings.

    /code/rcpp | permanent link

    Sun, 02 Nov 2014

    RcppArmadillo 0.4.500.0

    A few days ago, Conrad provided another minor release of Armadillo. Once again, I had created a GitHub-only pre-release of his pre-release which was tested against (then) all ninety (!!) CRAN dependents of our RcppArmadillo package, providing a further test for Conrad's code and uploaded RcppArmadillo 0.4.500.0 to CRAN and Debian once his release was finalized.

    The few changes from his end are summarized below; our end also includes an update / extension to the sample() method provided by Christian Gunning --- and used to great effect in the excellent Rcpp Gallery post by Jonathan Olmsted.

    Changes in RcppArmadillo version 0.4.500.0 (2014-10-30)

    • Upgraded to Armadillo release Version 4.500 ("Singapore Sling")

      • faster handling of complex vectors by norm()

      • expanded chol() to optionally specify output matrix as upper or lower triangular

      • better handling of non-finite values when saving matrices as text files

    • The sample functionality has been extended to provide the Walker Alias method (including new unit tests) via a pull request 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.

    This post by Dirk Eddelbuettel originated on his Thinking inside the box blog. Please report excessive re-aggregation in third-party for-profit settings.

    /code/rcpp | permanent link

    Mon, 29 Sep 2014

    Rcpp 0.11.3

    A new release 0.11.3 of Rcpp is now on the CRAN network for GNU R, and an updated Debian package has been uploaded too.

    Rcpp has become the most popular way of enhancing GNU R with C++ code. As of today, 273 packages on CRAN depend on Rcpp for making analyses go faster and further.

    This release brings a fairly large number of continued enhancements, fixes and polishing to Rcpp. These were provided by a total of seven different contributors---which is a new record as well.

    See below for a detailed list of changes extracted from the NEWS file, but some highlights included in this release are

    • Several API cleanups, polishes and a pre-announced code removal
    • New InternalFunction interface, and new Timer functionality.
    • More robust functionality of Rcpp Attributes as well as a new dryRun option.
    • The Rcpp FAQ was updated, as was the main Description: in the DESCRIPTION file.
    • Rcpp.package.skeleton() can now deploy functionality from pkgKitten to create Rcpp packages that purr.

    One sore point, however, is that we missed that packages using Rcpp Modules appear to require a rebuild. We are sorry for the inconvenience; this has highlighted a shortcoming in our fairly robust and extensive tests. While we test our packages against all known CRAN dependents, such tests check for the ability to compile and run freshly and not whether previously built packages still run. We intend to augment our testing in this direction to avoid a repeat occurrence of such a misfeature.

    Changes in Rcpp version 0.11.3 (2014-09-27)

    • Changes in Rcpp API:

      • The deprecation of RCPP_FUNCTION_* which was announced with release 0.10.5 last year is proceeding as planned, and the file macros/preprocessor_generated.h has been removed.

      • Timer no longer records time between steps, but times from the origin. It also gains a get_timers(int) methods that creates a vector of Timer that have the same origin. This is modelled on the Rcpp11 implementation and is more useful for situations where we use timers in several threads. Timer also gains a constructor taking a nanotime_t to use as its origin, and a origin method. This can be useful for situations where the number of threads is not known in advance but we still want to track what goes on in each thread.

      • A cast to bool was removed in the vector proxy code as inconsistent behaviour between clang and g++ compilations was noticed.

      • A missing update(SEXP) method was added thanks to pull request by Omar Andres Zapata Mesa.

      • A proxy for DimNames was added.

      • A no_init option was added for Matrices and Vectors.

      • The InternalFunction class was updated to work with std::function (provided a suitable C++11 compiler is available) via a pull request by Christian Authmann.

      • A new_env() function was added to Environment.h

      • The return value of range eraser for Vectors was fixed in a pull request by Yixuan Qiu.

    • Changes in Rcpp Sugar:

      • In ifelse(), the returned NA type was corrected for operator[].

    • Changes in Rcpp Attributes:

      • Include LinkingTo in DESCRIPTION fields scanned to confirm that C++ dependencies are referenced by package.

      • Add dryRun parameter to sourceCpp.

      • Corrected issue with relative path and R chunk use for sourceCpp.

    • Changes in Rcpp Documentation:

      • The Rcpp-FAQ vignette was updated with respect to OS X issues.

      • A new entry in the Rcpp-FAQ clarifies the use of licenses.

      • Vignettes build results no longer copied to /tmp to please CRAN.

      • The Description in DESCRIPTION has been shortened.

    • Changes in Rcpp support functions:

      • The Rcpp.package.skeleton() function will now use pkgKitten package, if available, to create a package which passes R CMD check without warnings. A new Suggests: has been added for pkgKitten.

      • The modules=TRUE case for Rcpp.package.skeleton() has been improved and now runs without complaints from R CMD check as well.

    • Changes in Rcpp unit test functions:

      • Functions from the RUnit package are now prefixed with RUnit::

      • The testRcppModule and testRcppClass sample packages now pass R CMD check --as-cran cleanly with NOTES or WARNINGS

    Thanks to CRANberries, you can also look at a diff to the previous release As always, even fuller details are on the Rcpp Changelog page and the Rcpp page which also leads to the downloads page, 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.

    This post by Dirk Eddelbuettel originated on his Thinking inside the box blog. Please report excessive re-aggregation in third-party for-profit settings.

    /code/rcpp | permanent link