comp.lang.idl-pvwave archive
Messages from Usenet group comp.lang.idl-pvwave, compiled by Paulo Penteado

Home » Public Forums » archive » Read ".mat" files
Show: Today's Messages :: Show Polls :: Message Navigator
E-mail to friend 
Return to the default flat view Create a new topic Submit Reply
Re: Read ".mat" files [message #15011 is a reply to message #14938] Tue, 13 April 1999 00:00 Go to previous message
Nigel Wade is currently offline  Nigel Wade
Messages: 286
Registered: March 1998
Senior Member
Alberto Verga wrote:
>
> Does anyone know how to read binary matlab .MAT files?
>
> ".MAT" are binary data files created using the save command in MATLAB,
> for example
>> a = zeros(100) %define array a(100,100)
>> save data a %write array a in file data.mat
>
> Is there any IDL "pro" code to read such files?
>
> Thanks.
> A. Verga.
>
> --

I have a .pro which can read simple MATLAB version 4 files.
By simple I mean full and string matrices but not sparse matrices.

Reading MATLAB version 5 files requires you to use the MATLAB library to
access
the data file as the format of the files is not in the public domain.
This
would require writing a LINKIMAGE interface or a DLM to load the
contents into
IDL variables.

If your data is saved by vn. 4, or you can save it as vn. 4 then you
could try my
routine to see if it loads your data.

BTW, it won't convert the "endian-ness" of the data. The MATLAB data
files must
be the same as the machine architecture.

If you would like to try it, e-mail me and I will send you a copy.

--
-----------------------------------------------------------
Nigel Wade, System Administrator, Space Plasma Physics Group,
University of Leicester, Leicester, LE1 7RH, UK
E-mail : nmw@ion.le.ac.uk
Phone : +44 (0)116 2523568, Fax : +44 (0)116 2523555
[Message index]
 
Read Message
Read Message
Previous Topic: arrays within structures
Next Topic: renaming idl-mode.el for GNU Emacs

-=] Back to Top [=-
[ Syndicate this forum (XML) ] [ RSS ] [ PDF ]

Current Time: Fri Oct 10 20:03:22 PDT 2025

Total time taken to generate the page: 0.63985 seconds