convert 1x1 struct mat file to xlsx
Show older comments

my sample.mat file has the following 1x1 structure, I need script to convert this mat file into an excel file.
2 Comments
KSSV
on 28 Mar 2017
Why you want it in xlsx? You have it in .mat file already.
Jaya sri Sunkara
on 28 Mar 2017
For some confined reasons, i need it in xlsx
Answers (1)
ES
on 28 Mar 2017
0 votes
First get all members of the structure using fields command.
Then iterate over the structure and write values in the excel sheet using xlswrite
If you encounter a structure of structure, do the fields again [recursive].
Categories
Find more on Spreadsheets in Help Center and File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!