Data Import/export from figure Matlab GUI
1 Ansicht (letzte 30 Tage)
Ältere Kommentare anzeigen
Hello, I need to analyze some data for experiment. So, I read the data from .txt file into the Matlab GUI and plotted a figure in log scale. Now, How can I return the data into Excel file/Notepad from the plotted figure of Matlab GUI. Can anybody help me?
Thanks..... D Bhuiyan
0 Kommentare
Akzeptierte Antwort
Fangjun Jiang
am 5 Nov. 2011
After processing your original data, you can use xlswrite() or dlmwrite() or csvwrite() to write the data to a file. For more flexible output, you need to use fopen(), fprintf(),fclose(). Check the help for sprintf() to find out the output format.
Simple example if you just want to output a regular numerical matrix.
xlswrite('test.xls', rand(3,4));
csvwrite('test.csv',rand(4,5);
1 Kommentar
Fangjun Jiang
am 6 Nov. 2011
xlswrite() is straightforward. Did you try the above example? If you have numerical data mixed with strings, you can use cell array.
c={'ab',1 4;400,0.4,'akdjf'};
xlswrite('test.xls',c);
Weitere Antworten (0)
Siehe auch
Kategorien
Mehr zu Text Files finden Sie in Help Center und File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!