Koen Hufkens, PhD<p>So, I'm coming from Fortran mostly, moving to C++, and I've this explicitly vectorized Fortran code which runs column wise operations, e.g.: </p><p>a = input(:, 1) + input(:, 2)</p><p>Now, I'm wondering how to implement this the fastest using Rcpp/C++.</p><p>I can use (Rcpp)Armadillo to implement the implicit logic, or loop through vector elements. Since the overhead of flipping between the two is quite some work I would love someone's take up front.</p><p><span class="h-card" translate="no"><a href="https://mastodon.social/@eddelbuettel" class="u-url mention" rel="nofollow noopener" target="_blank">@<span>eddelbuettel</span></a></span> <span class="h-card" translate="no"><a href="https://mastodon.social/@eliocamp" class="u-url mention" rel="nofollow noopener" target="_blank">@<span>eliocamp</span></a></span> ?</p><p><a href="https://mastodon.social/tags/rstats" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>rstats</span></a> <a href="https://mastodon.social/tags/devops" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>devops</span></a> <a href="https://mastodon.social/tags/Cpp" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>Cpp</span></a></p>