An R interface to the autodiff C++ library using Rcpp. autodiff is a modern, header-only C++17 library which provides an efficient and simple interface to perform automatic differentiation in C++. autodiff supports both forward and reverse mode of automatic differentiation. Rcppautodiff brings these capabilities to R. For more details on the autodiff library, please see its documentation and tutorials.
The vignette of this package also reproduces a number of examples from the autodiff library in R using Rcpp.
Rcppautodiff can be installed from CRAN using the following command in the R console.
install.packages("Rcppautodiff")The development version can be installed from github.
pak::pkg_install('sn248/Rcppautodiff')See the package vignette for a variety of examples.
This package would not exist without the wonderful autodiff, a modern, fast and expressive C++ library for automatic differentiation (by Allan M. M. Beal), found at https://autodiff.github.io/