how to use xmlread in a very simple example
19 vues (au cours des 30 derniers jours)
Afficher commentaires plus anciens
Bruce McWhorter
le 12 Juil 2018
Modifié(e) : Guillaume
le 12 Juil 2018
I would like a very simple example for reading numeric data from a xml file using xml read. I would like the xml file to be something like:
<!-- This is a simple xml file containing data -->
<file>
<data>
<variable1>100</variable1>
<variable2>200</variable2>
</data>
</file>
Réponse acceptée
Guillaume
le 12 Juil 2018
I would recommend you use xml2struct to save you having to navigate the xml DOM returned by xmlread.
xml = xml2struct(yourxmlfile);
xml.file.data.variable1
xml.file.data.variable2
0 commentaires
Plus de réponses (0)
Voir également
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!