<?xml version="1.0" encoding="UTF-8"?><rss
version="2.0"
xmlns:content="http://purl.org/rss/1.0/modules/content/"
xmlns:dc="http://purl.org/dc/elements/1.1/"
xmlns:atom="http://www.w3.org/2005/Atom"
xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
> <channel><title>Comments on: Undocumented XML functionality</title> <atom:link href="http://undocumentedmatlab.com/blog/undocumented-xml-functionality/feed/" rel="self" type="application/rss+xml" /><link>http://undocumentedmatlab.com/blog/undocumented-xml-functionality/</link> <description>Charting Matlab's unsupported hidden underbelly</description> <lastBuildDate>Mon, 21 May 2012 11:05:42 +0000</lastBuildDate> <sy:updatePeriod>hourly</sy:updatePeriod> <sy:updateFrequency>1</sy:updateFrequency> <generator>http://wordpress.org/?v=3.1.1</generator> <item><title>By: Yair Altman</title><link>http://undocumentedmatlab.com/blog/undocumented-xml-functionality/#comment-73071</link> <dc:creator>Yair Altman</dc:creator> <pubDate>Thu, 02 Feb 2012 00:47:54 +0000</pubDate> <guid
isPermaLink="false">http://undocumentedmatlab.com/?p=751#comment-73071</guid> <description>@James - I don&#039;t have an immediate answer for you, it requires some investigation. This sounds like a good idea for a future article. If you cannot wait for this article to appear, you could contact me by email (link at the top right of this page) to discuss a short consulting gig.</description> <content:encoded><![CDATA[<p>@James &#8211; I don&#8217;t have an immediate answer for you, it requires some investigation. This sounds like a good idea for a future article. If you cannot wait for this article to appear, you could contact me by email (link at the top right of this page) to discuss a short consulting gig.</p> ]]></content:encoded> </item> <item><title>By: James Myatt</title><link>http://undocumentedmatlab.com/blog/undocumented-xml-functionality/#comment-73029</link> <dc:creator>James Myatt</dc:creator> <pubDate>Wed, 01 Feb 2012 12:10:10 +0000</pubDate> <guid
isPermaLink="false">http://undocumentedmatlab.com/?p=751#comment-73029</guid> <description>@Yair, That certainly sounds like a better idea, but I&#039;m not sure how to proceed. Could you indicate how to modify the parseXML function from the xmlread help so that it used the SAX parser rather than the DOM returned by xmlread? Or am I on the wrong track?</description> <content:encoded><![CDATA[<p>@Yair, That certainly sounds like a better idea, but I&#8217;m not sure how to proceed. Could you indicate how to modify the parseXML function from the xmlread help so that it used the SAX parser rather than the DOM returned by xmlread? Or am I on the wrong track?</p> ]]></content:encoded> </item> <item><title>By: Yair Altman</title><link>http://undocumentedmatlab.com/blog/undocumented-xml-functionality/#comment-72787</link> <dc:creator>Yair Altman</dc:creator> <pubDate>Mon, 30 Jan 2012 22:42:18 +0000</pubDate> <guid
isPermaLink="false">http://undocumentedmatlab.com/?p=751#comment-72787</guid> <description>@James - DOM is normally used for small XML models; SAX is usually better for large models that can be processed sequentially. There are numerous SAX parsers available online that you can use in Matlab. Perhaps the most widely used open-source XML parser, which includes support fro both SAX and DOM, is Xerces, which is already pre-bundled in Matlab (take a look at the &lt;i&gt;%matlabroot%/java/jarext/&lt;/i&gt; folder), so you can use it in Matlab out-of-the-box. Other well-known XML support packages, namely Xalan and Saxon, are also pre-bundled.</description> <content:encoded><![CDATA[<p>@James &#8211; DOM is normally used for small XML models; SAX is usually better for large models that can be processed sequentially. There are numerous SAX parsers available online that you can use in Matlab. Perhaps the most widely used open-source XML parser, which includes support fro both SAX and DOM, is Xerces, which is already pre-bundled in Matlab (take a look at the <i>%matlabroot%/java/jarext/</i> folder), so you can use it in Matlab out-of-the-box. Other well-known XML support packages, namely Xalan and Saxon, are also pre-bundled.</p> ]]></content:encoded> </item> <item><title>By: James Myatt</title><link>http://undocumentedmatlab.com/blog/undocumented-xml-functionality/#comment-72783</link> <dc:creator>James Myatt</dc:creator> <pubDate>Mon, 30 Jan 2012 21:46:58 +0000</pubDate> <guid
isPermaLink="false">http://undocumentedmatlab.com/?p=751#comment-72783</guid> <description>xmlread does a great job of parsing an XML file, but I&#039;ve found that actually extracting data from the DOM hierarchy is pretty slow. For example, the parseXML function in the xmlread help takes about 250 times longer than the call to xmlread itself and vast majority of that time is spent interrogating the DOM objects.Do you have any suggestions?</description> <content:encoded><![CDATA[<p>xmlread does a great job of parsing an XML file, but I&#8217;ve found that actually extracting data from the DOM hierarchy is pretty slow. For example, the parseXML function in the xmlread help takes about 250 times longer than the call to xmlread itself and vast majority of that time is spent interrogating the DOM objects.</p><p>Do you have any suggestions?</p> ]]></content:encoded> </item> <item><title>By: Yair Altman</title><link>http://undocumentedmatlab.com/blog/undocumented-xml-functionality/#comment-4530</link> <dc:creator>Yair Altman</dc:creator> <pubDate>Sat, 21 Nov 2009 16:36:23 +0000</pubDate> <guid
isPermaLink="false">http://undocumentedmatlab.com/?p=751#comment-4530</guid> <description>Here&#039;s a nicer &quot;pretty-print&quot;, which uses the undocumented InputSource input argument format of &lt;b&gt;&lt;i&gt;xlswrite&lt;/i&gt;&lt;/b&gt;:&lt;pre lang=&quot;matlab&quot;&gt;
fReader=java.io.FileReader(java.io.File(which(&#039;info.xml&#039;)));
xmlwrite(org.xml.sax.InputSource(fReader))
&lt;/pre&gt;</description> <content:encoded><![CDATA[<p>Here&#8217;s a nicer &#8220;pretty-print&#8221;, which uses the undocumented InputSource input argument format of <b><i>xlswrite</i></b>:</p><div
class="wp_syntax"><div
class="code"><pre class="matlab" style="font-family:monospace;">fReader=java.<span style="">io</span>.<span style="">FileReader</span><span style="color: #080;">&#40;</span>java.<span style="">io</span>.<span style="">File</span><span style="color: #080;">&#40;</span><span style="color: #0000FF;">which</span><span style="color: #080;">&#40;</span><span style="color:#A020F0;">'info.xml'</span><span style="color: #080;">&#41;</span><span style="color: #080;">&#41;</span><span style="color: #080;">&#41;</span>;
xmlwrite<span style="color: #080;">&#40;</span>org.<span style="">xml</span>.<span style="">sax</span>.<span style="">InputSource</span><span style="color: #080;">&#40;</span>fReader<span style="color: #080;">&#41;</span><span style="color: #080;">&#41;</span></pre></div></div>]]></content:encoded> </item> <item><title>By: Donn Shull</title><link>http://undocumentedmatlab.com/blog/undocumented-xml-functionality/#comment-4491</link> <dc:creator>Donn Shull</dc:creator> <pubDate>Fri, 20 Nov 2009 17:58:22 +0000</pubDate> <guid
isPermaLink="false">http://undocumentedmatlab.com/?p=751#comment-4491</guid> <description>Hi Yair,It seems that many people follow an unusal convention for the format of their xml files. Even The MathWork&#039;s info.xml files don&#039;t following the standard indented form for xml files. A quick way to &quot;pretty print&quot; an xml file is to use saveXML method of the DOM node ie:&lt;pre lang=&quot;matlab&quot;&gt;
x = xmlread(which(&#039;info.xml&#039;));
x.saveXML(x.getDocumentElement)
&lt;/pre&gt;Thanks for the good work,Donn</description> <content:encoded><![CDATA[<p>Hi Yair,</p><p>It seems that many people follow an unusal convention for the format of their xml files. Even The MathWork&#8217;s info.xml files don&#8217;t following the standard indented form for xml files. A quick way to &#8220;pretty print&#8221; an xml file is to use saveXML method of the DOM node ie:</p><div
class="wp_syntax"><div
class="code"><pre class="matlab" style="font-family:monospace;">x = xmlread<span style="color: #080;">&#40;</span><span style="color: #0000FF;">which</span><span style="color: #080;">&#40;</span><span style="color:#A020F0;">'info.xml'</span><span style="color: #080;">&#41;</span><span style="color: #080;">&#41;</span>;
x.<span style="">saveXML</span><span style="color: #080;">&#40;</span>x.<span style="">getDocumentElement</span><span style="color: #080;">&#41;</span></pre></div></div><p>Thanks for the good work,</p><p>Donn</p> ]]></content:encoded> </item> </channel> </rss>

<!-- W3 Total Cache: Minify debug info:
Engine:             disk: basic
Theme:              b7666
Template:           single
-->
<!-- Performance optimized by W3 Total Cache. Learn more: http://www.w3-edge.com/wordpress-plugins/

Served from: undocumentedmatlab.com @ 2012-05-21 20:54:25 -->

<!-- W3 Total Cache: Page cache debug info:
Engine:             disk: enhanced
Cache key:          blog/undocumented-xml-functionality/feed/_index.xml_gzip
Caching:            enabled
Status:             not cached
Creation Time:      0.493s
Header info:
X-Pingback:         http://undocumentedmatlab.com/blog/xmlrpc.php
Set-Cookie:         wpgb_visit_last_php-default=1337658865; expires=Wed, 22-May-2013 03:54:25 GMT; path=/
Link:               <http://undocumentedmatlab.com/?p=751>; rel=shortlink
Content-Type:       text/xml; charset=UTF-8
Last-Modified:      Tue, 22 May 2012 03:54:25 GMT
Vary:               Accept-Encoding, Cookie
Expires:            Tue, 22 May 2012 04:54:25 GMT
Pragma:             public
Cache-Control:      public, must-revalidate, proxy-revalidate
Etag:               361998a4be73a5356fa0e23061bba600
Content-Encoding:   gzip
-->
