Kevin J. McCann wrote:
I have some data that I received from a colleague that is a rather
large mat file. "Data.mat". The file was generated with Matlab
2007b. I tried the following:
Import["Data.mat"]
Import["Data.mat","MAT"]
Import["Data.mat","mat"]
and they all give me an error:
Import::fmterr: "Cannot import data as MAT format."
Thanks,
Kevin
--
Kevin J. McCann
Research Associate Professor
JCET/Physics
Physics Building
University of Maryland, Baltimore County
1000 Hilltop Circle
Baltimore, MD 21250
John Jowett
Mathematica 6.0.1 cannot import version 7 .mat files.
Ideally, your colleague should export the files
using the following syntax:
>> save -v6 Data.mat;
If that is not an option, you can download Octave, an
open source Matlab clone, from http://www.octave.org/.
You can then read the .mat file into Octave and save
it in the correct format via:
>> load Data.mat;
>> save -v6 Data2.mat;
Mark
>Kevin J. McCann wrote: I have some data that I received from a
>colleague that is a rather large mat file. "Data.mat". The file was
>generated with Matlab 2007b.
Per the documentation that can be found at ref/format/MAT,
Import can deal with MAT files produced by version 4 and 5 of
Matlab. Possibly this is the issue? If the default save format
of the version your colleague is using differers from what
Import expects, that would account for your difficulty.
The phrasing in the documentation for the MAT format used by
Mathematica implicitly assumes later versions of Matlab will
create either level 4 or level 5 MAT files. It does not and
cannot guarantee later versions of Matlab by default create such files.
--
To reply via email subtract one hundred and four