I was wondering what is the correct way to get the C/C++ source code of any secondary(to distinguish from the Primitive/Internal ones) function in R. Related questions are here, here, here and here:
Mine is different so that I used "secondary" in my question. For example, the read.table() function, within R console I got:
>?read.table
read.table package:utils R Documentation
Data Input
Description:
Reads a file in table format and creates a data frame from it,
with cases corresponding to lines and variables to fields in the
file.
Usage:
read.table(file, header = FALSE, sep = "", quote = "\"'",
......
Or
> getAnywhere(read.table)
A single object matching ‘read.table’ was found
It was found in the following places
package:utils
namespace:utils
with value
function (file, header = FALSE, sep = "", quote = "\"'", dec = ".",
......
attr(data, "row.names") <- row.names
data
}
<bytecode: 0x560ff88edd40>
<environment: namespace:utils>
Search the website I got:
https://svn.r-project.org/R/trunk/src/library/utils/src/utils.c
https://svn.r-project.org/R/trunk/src/library/utils/src/utils.h
How to get the C/C++ source code of the read.table function instead of R code, if this is reasonable?