See other catalogues for
The MathWorks
You may also be interested in
Text version of the page
| | | | | | | | | | | | | | | | |
| | | |
| | | Using MAT-Files | | |
| | | |
| | | Both types of files can be transported directly between machines: M-files because they are platform independent and MAT-files because they contain a machine signature in the file header. MATLAB checks the signature when it loads a file and, if a signature indicates that a file is foreign, performs the necessary conversion. Using MATLAB across different machine architectures requires a facility for exchanging both binary and ASCII data between the machines. Examples of this type of facility include FTP, NFS, and Kermit. When using these programs, be careful to transmit MAT-files in binary file mode and M-files in ASCII file mode. Failure to set these modes correctly corrupts the data. | | |
| | | |
| | | Reading and Writing MAT-Files Use the save function to save MATLAB arrays currently in memory to a binary file called a MAT-file. MAT-files have the extension .mat.The load command reads MATLAB arrays from a MAT-file on disk back into the MATLAB workspace. A MAT-file contains one or more of the data types supported in MATLAB version 5 or later, including strings, matrices, multidimensional arrays, structures, and cell arrays. MATLAB writes the data sequentially onto disk in a continuous byte stream. | | |
| | | |
| | | MAT-File Interface Library TheMAT-fileinterfacelibrarycontainsroutinesforreadingandwriting MAT-files. You can call these routines from your own C and Fortran programs. Use these routines, rather than attempt to write your own code, to perform these operations, since using the library insulates your applications from future changes to the MAT-file structure. Functions in the MAT-file library begin with the three-letter prefix mat.These tables list and describe the MAT-functions. | | |
| | | |
| | | CMAT-FileRoutines | | |
| | | |
| | | | | | | | | | MAT-Function | Purpose | | | | matOpen | Open a MAT-file. | | | | | | | | | |
| | | |
| | | 1-5 | | |
| | | |
| | | | | | | | | | | | | | | | |