[R] Trycatch in R

Archit Soni soni.archit1989 at gmail.com
Tue Dec 22 13:34:46 CET 2015

Hi All,

Please help me in the below code:

 x <- capture.output(XML::xmlParse(y))
}, warning = function(w) {
  x <- capture.output(w)
}, error = function(e) {
  x <-capture.output(e)
}, finally = {


I am using Tibco Enterprise Runtime for R to get value of the parsed XML in
vector format, and spotfire is displaying each line as a row in new table,
but can you please suggest how to do error handling in this case when no
row is selected and we run this script, it is throwing error for length of
argument is 0, i need to display an error message as first row of the table.

Please suggest.


	[[alternative HTML version deleted]]

More information about the R-help mailing list