Hi,

Consider the following code:

	  require(XML)
	  xmlFile = paste( "<?xml version=\"1.0\"
encoding=\"ISO-8859-1\"?>\n", 
	            "<mzXML xmlns=\"a\" xmlns:xsi=\"b\"
xsi:schemaLocation=\"c\">\n",
	            "<parentFile a=\"a\" b=\"b\" />\n",
	            "</mzXML>\n")
	  cat(xmlFile)
	  
	  a = function(x,...){
	    cat("Attributes of ", xmlName(x), ": "); 
	    print(xmlAttrs(x));
	    cat("\n"); 
	    NULL
	  }
	  
	  xmlTreeParse(file=xmlFile, asText=TRUE,
handlers=list("startElement"=a) )

And its output:

	 <?xml version="1.0" encoding="ISO-8859-1"?>
	 <mzXML xmlns="a" xmlns:xsi="b" xsi:schemaLocation="c">
	 <parentFile a="a" b="b" />
	 </mzXML>

	Attributes of  parentFile :   a   b 
	                                     "a" "b" 

	Attributes of  mzXML : schemaLocation 
	                                  "c" 
It seems to me that XML parser was able to correctly list all the attributes
of the "parentFile" node but it failed on "mzXML" node.
Am I missusing the functions somehow or is it a bug?
Attribute names in "mzXML" node are part of mzXML file format and can not be
changed (removing all ':' would fix the problem) and I would like to store
than so whan I write mzXML file I have the same header.

Jarek
====================================================\=======

 Jarek Tuszynski, PhD.                           o / \ 
 Science Applications International Corporation  <\__,|  
 (703) 676-4192                                   ">   \
 Jaroslaw.W.Tuszynski@saic.com                     `    \



	[[alternative HTML version deleted]]


