Extracting data from .mat file
1 visualizzazione (ultimi 30 giorni)
Mostra commenti meno recenti
Hi everyone, I have received a *.mat file from my supervisor that contains 4 tables. every table is constructed on hourly based data from a power generator, 24 hours a day and 365 days a year. so it (24*365)= 8760x1 table. that the properties of the table ''Time vector characteristics
Length 8760
Start date 01-Jan-2006 01:00:00
End date 01-Jan-2007 00:00:00
''
I need to extract data from the table in such form that I re-arrange it into 365x24 matrix so that every row show data for 1 day with 24 hours.
0 Commenti
Risposta accettata
Mitch Martelli
il 28 Nov 2012
Sorry i dont understand well your question
to extract the data you can try to use getEntry, documentation are reported in the link below :
Moreover if i understand well your aim reshape(xxx,365,24) dont give you what you want.
B = reshape(xxx,24,365);
B=B';
Più risposte (2)
Mitch Martelli
il 28 Nov 2012
Hi, You can use the reshape function.
Example :
data=rand(8760,1)
B = reshape(data,24,365);
B=B';
Regards
M1tC4
0 Commenti
Image Analyst
il 28 Nov 2012
What is stored in the mat file? Is it a structure with a cell array with 4 cells, and inside each cell is another cell array that is the table? So basically in other words there are 4 tables. And each table is an (N rows) by (3 columns) cell array where each of those cells contains a string? Because that's what you're showing. Can you do this and tell us what shows up in the command window:
storedStructure = load(yourMatFileName);
whos storedStructure
storedStructure
Vedere anche
Categorie
Scopri di più su Spreadsheets in Help Center e File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!