How do I read in the data from 23 sheets/tabs (of excel file) and create field (within a structure) that contains each tab's data?
Mostra commenti meno recenti
Hi all, I have an excel file with 23 sheets/tabs. I want to read the data from each sheet/tab and assign the data into separate fields (within a structure) for each sheet/tab. Is this possible? Can I do it using a loop, instead of individually? Thank you
3 Commenti
Hermes Suen
il 5 Lug 2018
Does it need to be in a struct, or could you import into a table? What does the data look like? If it it is organized by columns you can consider using a Table which would be easier. If it is a table, then you can create a cell array of the numbers 1-23, and use a loop (happy to show you some example code if it is). Do you want the data from each sheet to go into a specific field in a larger Struct, or does EACH sheet have its OWN struct?
Mathew Grey
il 6 Lug 2018
Modificato: per isakson
il 6 Lug 2018
Image Analyst
il 7 Lug 2018
I can't seem to find where you attached the workbook. What question or comment did you attach it to?
Risposta accettata
Più risposte (1)
Mathew Grey
il 8 Lug 2018
0 voti
Categorie
Scopri di più su Loops and Conditional Statements in Centro assistenza e File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!