Easily create a Microsoft Excel format spreadsheet from MATLAB®.
You are now following this Submission
- You will see updates in your followed content feed
- You may receive emails, depending on your communication preferences
NOTE: I built this a million years ago, before it was provided with MATLAB. I recommend you use xlswrite, or even better writetable, that have been in MATLAB for many years now.
Creates a Microsoft Excel format spreadsheet using the MATLAB ActiveX interface. This can also open the spreadsheet directly without ever saving to a file.
Nothing too fancy:
- Supports arbitrary number of header lines
- Supports column headers
- Writes a single matrix
- Can write to specific sheets (thanks Fahad!)
Example:
m = rand(100,4);
header = 'This is some introductory information at the top of my spreadsheet.';
colnames = {'Ch1','Ch2','Ch3','Ch4'};
filename = 'myfile.xls';
xlswrite(m,header,colnames,filename);
Will create a spreadsheet named myfile.xls
Cite As
Michelle Hirsch (2026). xlswrite - legacy (https://github.com/michellehirsch/xlswrite--Legacy), GitHub. Retrieved .
Acknowledgements
Inspired: xlsheets, dat2xls, xlschart, XLSWriteMex, table2word, xlswrite_mod, xlcolumn, xlswrite, Example of how to save or read data to an Excel archive.
General Information
- Version 1.2.0.1 (4.71 KB)
-
View License on GitHub
MATLAB Release Compatibility
- Compatible with any release
Platform Compatibility
- Windows
- macOS
- Linux
Versions that use the GitHub default branch cannot be downloaded
