Hi,
On Aug 6, 2009, at 7:25 PM, [Ricardo Rodriguez] Your XEN ICT Team wrote:
Please, could you give me an example about how to use cat() to read
the value of a variable in a function? Any other way?
Can you please give an example of what you're trying to do?
It seems like you're asking to use cat() for something it's not meant
to do. cat() is generally used to write output, either to the screen
or to a file.
I've found how to make it globally available, thus printing it, but
I don't know how to read out the value of any variable within the
function.
You can use cat *in* a function to print the value of a variable, but
you can't "reach into" a function to pull out a variable's value. Are
you trying to debug something? See: ?debug to step through a function
to examine what it's doing one step at a time.
-steve
--
Steve Lianoglou
Graduate Student: Computational Systems Biology
| Memorial Sloan-Kettering Cancer Center
| Weill Medical College of Cornell University
Contact Info: http://cbio.mskcc.org/~lianos/contact
______________________________________________
[email protected] mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
and provide commented, minimal, self-contained, reproducible code.