Blog Archives

RcppHoney Introduction

July 25, 2016
By
RcppHoney Introduction

Rationale In C++ we often have containers that are not compatible with R or Rcpp with data already in them (std::vector, std::set, etc.). One would like to be able to operate on these containers without having to copy them into Rcpp structures like I...

Read more »

Rcpp::algorithm

June 24, 2016
By
Rcpp::algorithm

Introduction A while back I saw a post on StackOverflow where the user was trying to use Rcpp::sugar::sum() on an RcppParallel::RVector. Obviously this doesn’t work and it raised the question “Why doesn’t something more generic exist to provide functions with R semantics that can be used on arbitrary data structures?” As a result, I set out to create a set of...

Read more »

Custom Templated as and wrap Functions within Rcpp.

June 24, 2016
By
Custom Templated as and wrap Functions within Rcpp.

Introduction Consider a need to be able to interface with a data type that is not presently supported by Rcpp. The data type might come from a new library or from within ones own program. In such cases, Rcpp is faced with an issue of consciousness as the new data type is not similar to known types so the autocoversion...

Read more »

Working with Rcpp::StringVector

June 22, 2016
By
Working with Rcpp::StringVector

Vectors are fundamental containers in R. This makes them equally important in Rcpp. Vectors can be useful for storing multiple elements of a common class (e.g., integer, numeric, character). In Rcpp, vectors come in the form of NumericVector, CharacterVector, LogicalVector, StringVector and more. Look in the header file Rcpp/include/Rcpp/vector/instantiation.h for more types. Here we explore how to work with Rcpp::StringVector as a way to...

Read more »

Optimizing Code vs Recognizing Patterns with 3D Arrays

June 7, 2016
By
Optimizing Code vs Recognizing Patterns with 3D Arrays

Intro As is the case with the majority of posts normally born into existence, there was an interesting problem that arose on recently on StackOverflow. Steffen, a scientist at an unnamed weather service, faced an issue with the amount of computational time required by his triple loop in R. Specifically, Steffen needed to be able to sum over...

Read more »

Hierarchical Risk Parity Implementation in Rcpp and OpenMP

May 26, 2016
By
Hierarchical Risk Parity Implementation in Rcpp and OpenMP

Summary Recently, there has been a new research paper coming out with the goal of improving Markowitz’s Critical Line Algorithm (CLA) published by Marcos Lopez de Prado. The methodology is also currently patent pending and the paper can be downloaded here. The methodology suggested by the paper proposes the Hierarchical Risk Parity (HRP) approach. The HRP approach aims at...

Read more »

Gerber Statistic Implementation in Rcpp and OpenMP

May 25, 2016
By
Gerber Statistic Implementation in Rcpp and OpenMP

Summary Recently new research has appeared on using a co-movement measure to construct the covariance matrix as part of the Modern Portfolio Theory (MPT) style portfolio construction. Below is the abstract of the Gerber, Markowith and Pujara (2015) paper whose methodology is also currently patent pending: Markowitz’s mean-variance MPT has remained the cornerstone of portfolio selection methods after decades of...

Read more »

SIMD Map-Reduction with RcppNT2

February 1, 2016
By
SIMD Map-Reduction with RcppNT2

Introduction The Numerical Template Toolbox (NT2) collection of header-only C++ libraries that make it possible to explicitly request the use of SIMD instructions when possible, while falling back to regular scalar operations when not. NT2 itself is powered by Boost, alongside two proposed Boost libraries – Boost.Dispatch, which provides a mechanism for efficient tag-based dispatch for functions, and Boost.SIMD, which provides a framework for the implementation of...

Read more »

Using RcppNT2 to Compute the Variance

January 31, 2016
By
Using RcppNT2 to Compute the Variance

Introduction The Numerical Template Toolbox (NT2) collection of header-only C++ libraries that make it possible to explicitly request the use of SIMD instructions when possible, while falling back to regular scalar operations when not. NT2 itself is powered by Boost, alongside two proposed Boost libraries – Boost.Dispatch, which provides a mechanism for efficient tag-based dispatch for functions, and Boost.SIMD, which provides a framework for the implementation of...

Read more »

Using RcppNT2 to Compute the Sum

January 31, 2016
By
Using RcppNT2 to Compute the Sum

Introduction The Numerical Template Toolbox (NT2) collection of header-only C++ libraries that make it possible to explicitly request the use of SIMD instructions when possible, while falling back to regular scalar operations when not. NT2 itself is powered by Boost, alongside two proposed Boost libraries – Boost.Dispatch, which provides a mechanism for efficient tag-based dispatch for functions, and Boost.SIMD, which provides a framework for the implementation of...

Read more »

Sponsors

Mango solutions



RStudio homepage



Zero Inflated Models and Generalized Linear Mixed Models with R

Quantide: statistical consulting and training

datasociety

http://www.eoda.de





ODSC

ODSC

CRC R books series





Six Sigma Online Training









Contact us if you wish to help support R-bloggers, and place your banner here.

Never miss an update!
Subscribe to R-bloggers to receive
e-mails with the latest R posts.
(You will not see this message again.)

Click here to close (This popup will not appear again)