Read and write data in spreadsheet files, including
Import spreadsheet data interactively using the Import Tool. Import or export spreadsheet data
programmatically using the functions on this page. To compare primary
import options for spreadsheet files, see Ways to Import Spreadsheets.
||Create table from file|
||Create import options based on file content|
||Write table to file|
||Determine if file contains Microsoft Excel spreadsheet|
||Read Microsoft Excel spreadsheet file|
||Write Microsoft Excel spreadsheet file|
||Load data from file|
||Import options object for Spreadsheets|
This example shows how to import data from a spreadsheet into the workspace with the Import Tool.
This example shows how to import mixed numeric
and text data from a spreadsheet into a table, using the
This example shows how to import worksheets
in an Excel file that contains only numeric data (no row or column
headers, and no inner cells with text) into a structure array, using
Microsoft Excel software can represent dates as text or numeric values.
This example shows how to export a numeric
array and a cell array to a Microsoft Excel spreadsheet file,
To import or export multiple files, create a control loop to process one file at a time.
Typically, you can import tables using the
You can import data from spreadsheet files into MATLAB® interactively, using the Import Tool, or programmatically, using an import function.
If your system has Excel for Windows® installed, including the COM server (part of the typical installation of Excel):