Skip to main content

RcppEigen

  • Chapter
  • First Online:
Seamless R and C++ Integration with Rcpp

Part of the book series: Use R! ((USE R,volume 64))

Abstract

The RcppEigen package provides an interface to the Eigen library. Eigen is a featureful C++ library which deploys modern template meta-programming techniques. It is similar to Armadillo but provides an even more granular application-programming interface (API). This chapter provides an introduction to the Rcpp Eigen package by introducing the core data structures, illustrating some of the available matrix decomposition methods and concludes with a case study of particular C++implementation (providing what is called a “factory” pattern) for different matrix decomposition approaches in order to provide a faster reimplementation of the lm method.

This is a preview of subscription content, log in via an institution to check access.

Access this chapter

Chapter
USD 29.95
Price excludes VAT (USA)
  • Available as PDF
  • Read on any device
  • Instant download
  • Own it forever
eBook
USD 69.99
Price excludes VAT (USA)
  • Available as EPUB and PDF
  • Read on any device
  • Instant download
  • Own it forever
Softcover Book
USD 89.99
Price excludes VAT (USA)
  • Compact, lightweight edition
  • Dispatched in 3 to 5 business days
  • Free shipping worldwide - see info

Tax calculation will be finalised at checkout

Purchases are for personal use only

Institutional subscriptions

Notes

  1. 1.

    See https://code.google.com/p/ceres-solver/.

  2. 2.

    A comment from another R / Eigen developer confirming this ratio is gratefully acknowledged.

  3. 3.

    The Eigen tutorial can be accessed via http://eigen.tuxfamily.org/dox, and more detailed documentation about matrix decompositions is at http://eigen.tuxfamily.org/dox/TopicLinearAlgebraDecompositions.html.

References

  • Abrahams D, Gurtovoy A (2004) C++ Template Metaprogramming: Concepts, Tools and Techniques from Boost and Beyond. Addison-Wesley, Boston

    Google Scholar 

  • Bates D, Eddelbuettel D (2013) Fast and elegant numerical linear algebra using the RcppEigen package. Journal of Statistical Software 52(5), URL http://www.jstatsoft.org/v52/i05

  • Bates D, François R, Eddelbuettel D (2012) RcppEigen: Rcpp integration for the Eigen templated linear algebra library. URL http://CRAN.R-Project.org/package=RcppEigen, R package version 0.3.1.2

  • François R, Eddelbuettel D (2010) RcppGSL: Rcpp integration for GNU GSL vectors and matrices. URL http://CRAN.R-Project.org/package=RcppGSL, R package version 0.2.0

  • François R, Eddelbuettel D, Bates D (2012) RcppArmadillo: Rcpp integration for Armadillo templated linear algebra library. URL http://CRAN.R-Project.org/package=RcppArmadillo, R package version 0.3.4.4

  • Guennebaud G, Jacob B, et al (2012) Eigen v3. URL http://eigen.tuxfamily.org

  • Sanderson C (2010) Armadillo: An open source C++ algebra library for fast prototyping and computationally intensive experiments. Tech. rep., NICTA, URL http://arma.sf.net

Download references

Author information

Authors and Affiliations

Authors

Rights and permissions

Reprints and permissions

Copyright information

© 2013 The Author

About this chapter

Cite this chapter

Eddelbuettel, D. (2013). RcppEigen. In: Seamless R and C++ Integration with Rcpp. Use R!, vol 64. Springer, New York, NY. https://doi.org/10.1007/978-1-4614-6868-4_12

Download citation

Publish with us

Policies and ethics