Writing an R package, I have a R function that calls a specific Rcpp function. The Rcpp function just serves as a helper function and I do not want to creat a .Rd file for i
There are two aspects here:
Have the C++ function callable from R. You need the // [[Rcpp::export]]
tag for that, and it will create an R interface.
Have that R/C++ interface function 'visible' to clients of the package. That is different and controlled by NAMESPACE
. Just do not list it there, only list your other function. You can still call it from the outside by using the colons: yourpackage:::yourCppFunction()
.
That way your C++ code is callable (per 1.) and does not need an Rd file (per 2. as it is not exported.) Only your visible R wrapper needs an man page entry.
For one worked example see this C++ file in the anytime package which is not in the NAMESPACE file, hence has no help page, yet is still callable to test code.