xml2struct

Convert an xml file into a MATLAB structure for easy access to the data.

Download
Download

You are now following this Submission

Cite As

Wouter Falkena (2026). xml2struct (https://in.mathworks.com/matlabcentral/fileexchange/28518-xml2struct), MATLAB Central File Exchange. Retrieved .

General Information

MATLAB Release Compatibility

  • Compatible with any release

Platform Compatibility

  • Windows
  • macOS
  • Linux
Version Published Release Notes Action
1.8.0

Small bugfix in the CDATA and Comment structure fields.

Download
1.7.0

Speed improvement due to X. Mo and added support for cdata and comments.

Download
1.5.0

The function now replaces element and attribute names containing - by _dash_, . by _dot_ and : by _colon_

Download
1.4.0

Attribute parsing speed increased by 40%

Download
1.3.0

Corrected the uploaded file

Download
1.2.0

Removed the assumption that the filename should have a '.xml' extension

Download
1.1.0

Decreased the processing time for large XML files

Download
1.0.0

Download