Olga Lyashevska
2010-Mar-05 12:09 UTC
[R] looking into function body without package installation
Dear all, I was wondering if there is a way to explore a syntax of particular function without package installation? I am trying to write my own functions, and I would like to see how other people approached similar problems. If every time I have to install/load package to be able to explore function syntax I end up installing loads of packages I am never going to use. I have also tried to use package 'sos' which does provide a good facility to find relevant information, but it seems it does not give any info on function body. Thanks, Olga
Duncan Murdoch
2010-Mar-05 12:25 UTC
[R] looking into function body without package installation
Olga Lyashevska wrote:> Dear all, > > I was wondering if there is a way to explore a syntax of particular > function without package installation? > I am trying to write my own functions, and I would like to see how > other people approached similar problems. If every time I have to > install/load package to be able to explore function syntax I end up > installing loads of packages I am never going to use. > > I have also tried to use package 'sos' which does provide a good > facility to find relevant information, but it seems it does not give > any info on function body. > >The source of CRAN packages is available to download from there. Sometimes the source gives better information than deparsed versions of functions: it shows all the functions in the order the author thought was sensible, it contains comments, etc. But it won't save much time compared to installing and loading the package. Duncan Murdoch