Rcpp at 1000 Reverse Depends: Some Observations
Dirk Eddelbuettel DSC 2017 July 3, 2017
Ketchum Trading; Debian and R Projects 1/23
Rcpp at 1000 Reverse Depends: Some Observations 2/23 More a stream - - PowerPoint PPT Presentation
Dirk Eddelbuettel DSC 2017 July 3, 2017 Ketchum Trading; Debian and R Projects 1/23 Rcpp at 1000 Reverse Depends: Some Observations 2/23 More a stream of consiousness Outline Some Notes about Rcpp, ever so briefly about testing
Ketchum Trading; Debian and R Projects 1/23
2/23
3/23
4/23
5/23
2010 2012 2014 2016 200 400 600 800 1000
Growth of Rcpp usage on CRAN
Number of CRAN packages using Rcpp (left axis) Percentage of CRAN packages using Rcpp (right axis) 200 400 600 800 1000 2010 2012 2014 2016 2 4 6 8 10 Data current as of July 1, 2017.
6/23
7/23
boot rgl raster doParallel zoo nlme RCurl RColorBrewer coda shiny XML reshape2 foreach magrittr data.table igraph jsonlite sp RcppArmadillo httr stringr lattice dplyr plyr survival mvtnorm Matrix ggplot2 MASS Rcpp 0.005 0.010 0.015 0.020 0.025
Top 30 of Page Rank as of July 2017
8/23
9/23
10/23
11/23
#include <R.h> #include <Rinternals.h> SEXP convolve2(SEXP a, SEXP b) { int na, nb, nab; double *xa, *xb, *xab; SEXP ab; a = PROTECT(coerceVector(a, REALSXP)); b = PROTECT(coerceVector(b, REALSXP)); na = length(a); nb = length(b); nab = na + nb - 1; ab = PROTECT(allocVector(REALSXP, nab)); xa = REAL(a); xb = REAL(b); xab = REAL(ab); for (int i = 0; i < nab; i++) xab[i] = 0.0; for (int i = 0; i < na; i++) for (int j = 0; j < nb; j++) xab[i + j] += xa[i] * xb[j]; UNPROTECT(3); return ab; }
12/23
13/23
14/23
15/23
16/23
17/23
18/23
19/23
20/23
21/23
22/23
23/23