Description Usage Arguments Details Value Author(s) References See Also Examples
This function runs a C++ version of the R function
convolve
, specifically: convolve(x,y,
conj=TRUE, type="open")
1 | rcpp_convolve(a, b)
|
a |
a numeric vector |
b |
a numeric vector |
The R function convolve
is an example of an
R function that gets very slow when the input vectors are
large. This C++ version, rcpp_convolve
can be
dramatically faster for large vectors.
rcpp_convolve
produces the same output as:
convolve(ca, cb, conj=TRUE, type="open")
Note: The C++ code is from the Rcpp examples in: Eddelbuettel & Francois (2011). Rcpp: Seamless R and C++ Integration. Journal of Statistical Software, 40(8), 1-18.
convolve_result_vector
the vector which is the
product of the convolution
C++ code by: Dirk Eddelbuettel <edd at debian.org> & Romain Francois (2011); This R wrapper & documentation: Nicholas Matzke matzke@berkeley.edu
Eddelbuettel D and Francois R (2011). "Rcpp: Seamless R and C++ Integration." _Journal of Statistical Software_, *40*(8), pp. 1-18. ISSN 1548-7660, See also: http://cran.r-project.org/web/packages/Rcpp/vignettes/Rcpp-introduction.pdf , http://cran.r-project.org/web/packages/Rcpp/index.html , <URL: http://www.jstatsoft.org/v40/i08>.
Rcpp
, convolve
,
rcpp_mult2probvect
,
Rcpp_combn_zerostart
1 2 3 4 5 6 7 |
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.