[R-pkg-devel] Searching examples in source code

Jeff Newmiller jdnewm|| @end|ng |rom dcn@d@v|@@c@@u@
Sun May 8 00:47:36 CEST 2022


I use grep, the old "general regular expression parser" at the bash command-line. It is also useful in conjunction with the "find" and "xargs".

You can also do these things with list.files and readLines and grep within R, but splatting it out onto a terminal screen with the "less" program is convenient.

On May 7, 2022 2:24:19 PM PDT, Ben Engbers <Ben.Engbers using Be-Logical.nl> wrote:
>Hi,
>
>My package (RBaseX) is written entirely in R. The performance is not bad but to further improve the performance I want to investigate to what extent use of C++ makes sense. Problem is that I have little experience with C++ and none with Rcpp. So I am looking for examples.
>On my (linux) system I installed several packages that needed to be compiled. So it is likely that I already have examples on my system.
>
>My first question is if there is a useful linux command to search all the source code of installed packages on my system.
>The second question is if there is a command to search all packages at https://cran.r-project.org/web/packages/available_packages_by_name.html?
>
>This question is not only relevant to C++ examples. It would also be nice if you could search for occurrences of commands in R code.
>
>Ben
>
>______________________________________________
>R-package-devel using r-project.org mailing list
>https://stat.ethz.ch/mailman/listinfo/r-package-devel

-- 
Sent from my phone. Please excuse my brevity.



More information about the R-package-devel mailing list