I have a mat-file that I accessed using
from scipy import io
mat = io.loadmat(\'example.mat\')
From matlab, example.mat contains the following
(!) In case of nested structures saved in *.mat
files, is necessary to check if the items in the dictionary that io.loadmat
outputs are Matlab structures. For example if in Matlab
>> thisStruct
ans =
var1: [1x1 struct]
var2: 3.5
>> thisStruct.var1
ans =
subvar1: [1x100 double]
subvar2: [32x233 double]
Then use the code by mergen in scipy.io.loadmat nested structures (i.e. dictionaries)