[R] How to step in a function?

David Winsemius dwinsemius at comcast.net
Thu Dec 3 05:12:25 CET 2009


On Dec 2, 2009, at 10:54 PM, Peng Yu wrote:

> On Wed, Dec 2, 2009 at 8:08 PM, David Winsemius <dwinsemius at comcast.net 
> > wrote:
>>
>> On Dec 2, 2009, at 8:58 PM, Peng Yu wrote:
>>
>>> To debug a function, what I currently know is to put 'browser()' in
>>> it. But I'm wondering if there is a way like 'step in' that is
>>> available in debuggers of other languages (e.g. gdb).
>>
>> Learn to search:
>>
>>> library(sos)
>>> ???"debug step"
>
> I download the document from cran. But I prefer to consult the
> document from R session. What command should I use to get the document
> for the package of sos?

The same way you would install any other package.

> What command should I use to get the list of
> functions that are in sos?

Most packages have an index. Some will display a list with:
help(package= <pkg-name> )

(Do you read r-help? Did you read any basic material? Seems as though  
this much should have crossed your eyes and brain before. )
--

David Winsemius, MD
Heritage Laboratories
West Hartford, CT




More information about the R-help mailing list