User Guide

By importing this package, you can use Bob native array reading ( and writing ( routines to load and save files using the Matlab(R) .mat format.

>>> import
>>> import #under the hood: loads Bob plugin for '.mat' files
>>> x ='myfile.mat') 

This package also contains a couple of other methods that allow for reading variable names and matrices from .mat files. Proceed to the Python API section for details.


Currently, reading the .mat files with a cell inside leads to a crash. You can refer to SciPy Cookbook for alternative solutions.

Be Portable

An alternative for saving data in .mat files using, would be to save them as HDF5 files which then can be easily read inside Matlab. The HDF5 format is well supported in Matlab(R) - as a matter of fact, the newest version of .mat files uses the HDF5 format.

Similarly, instead of having to read .mat files using, you can save your Matlab data in HDF5 format, which then can be easily read from Bob, without this add-on. Detailed instructions about how to save and load data from Matlab to and from HDF5 files can be found here.