Scilab 5.4.1
      
      
    Please note that the recommended version of Scilab is 2026.0.0. This page might be outdated.
See the recommended documentation of this function
matfile_open
Opens a Matlab binary MAT-file.
Calling Sequence
fd = matfile_open(filename[, mode])
Arguments
- filename
- String: the path of the file. Must contain only ANSI character. 
- mode
- String: file access type ( - "r"by default).- "r": opens the file for reading. 
- "w": opens the file for writing. 
 
- fd
- Real: file descriptor (-1 if opening failed). 
Description
Opens a Matlab binary MAT-file for reading or writing data.
|  | If  modeis set tow, the content offilenamewill be reseted. | 
Examples
A = rand(10,10); B = sprand(100,100,0.1); savematfile('test_matfile.mat','A','B','-v6'); clear(); fd = matfile_open("test_matfile.mat"); matfile_listvar(fd) matfile_close(fd); //fd = matfile_open("test_matfile.mat","w"); // Empty test_matfile.mat
See Also
- matfile_close — Closes a Matlab binary MAT-file.
- matfile_varreadnext — Reads next variable in a Matlab binary MAT-file.
- matfile_varwrite — Write a variable in a Matlab binary MAT-file.
- matfile_listvar — Lists variables of a Matlab binary MAT-file.
Bibliography
This function uses MATIO library (
            http://sourceforge.net/projects/matio/
            ).
| Report an issue | ||
| << matfile_listvar | Matlab binary files I/O | matfile_varreadnext >> |