Hi all,

What's the preferred way of capturing the expression representing the
contents of a function?

* body(write.csv) gives me a braced expression
* body(write.csv)[-1] gives me a mangled call
* as.list(body(write.csv)[-1]) gives me a list of calls
* as.expression(as.list(body(write.csv)[-1])) is what I want but seems
like too much work

Any suggestions?

Thanks,

Hadley

-- 
Assistant Professor / Dobelman Family Junior Chair
Department of Statistics / Rice University
http://had.co.nz/

______________________________________________
R-devel@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-devel

Reply via email to