Struct with multiple rows to excel file with one sheet per row
5 views (last 30 days)
Show older comments
Edited: Aymeric Ferreira on 30 Dec 2019
I'm working with structure and I would like to save the data into one excel file.
My structure is composed on 77 rows, each row is a 2D table that I output as a single Excel sheet in an Excel workbook.
I'm looping over each row for the moment but the problem is the code is quite slow, and the more rows I have, the longer is my saving.
My saving code is the following :
for i = 1:77
Data = struct2table(Data_struct(i));
It works well but I would like to speed it up. It took minimum 3 seconds to save one sheet and obviously it increases when the file grow up. Is there a way to save it without a loop ? Or save only one time ?
For a file of 4MB and 77 sheets it takes more than 5 minutes
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!