You can use MATLAB® Report Generator™ software to compare a pair of XML text files.
The XML comparison tool processes the results into a report that you can use to explore the file differences.
You can access the XML comparison tool from:
The MATLAB Current Folder browser context menu
The MATLAB command line.
The XML comparison tool compares the files using the "Chawathe" algorithm, as described in this paper:
|Change Detection in Hierarchically Structured Information, Sudarshan Chawathe, Anand Rajaraman, and Jennifer Widom; SIGMOD Conference, Montreal, Canada, June 1996, pp. 493-504.|
This conference paper is based upon work published in 1995: see http://dbpubs.stanford.edu:8090/pub/1995-45.
XML comparison reports display in the Comparison Tool. For more information about the Comparison Tool, see Comparing Files and Folders in the MATLAB documentation.
The XML comparison report shows a hierarchical view of the portions of the two XML files that differ. The report does not show sections of the files that are identical.
If the files are identical you see a message reporting there are no differences.
Change detection in the Chawathe analysis is based on a scoring algorithm. Items match if their Chawathe score is above a threshold. The MATLAB Report Generator implementation of Chawathe's algorithm uses a comparison pattern that defines the thresholds. For more information, see How the Matching Algorithm Works.