[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: matlab 5.? format

From: Erich Schneider
Subject: Re: matlab 5.? format
Date: Thu, 29 Oct 98 20:11:13

On Thu, 29 Oct 1998 16:18:06 +0100, Daniel Heiserer wrote:

>Well I have a C-routine (standalone) reading some data and writing
>mat-binarys which
>should be read by matlab/octave (both). Therefore I would need a 
>API to write matlab4.x files. Unfortunately I have only the matlab5 
>api. Does anybody have the matlab4.x api or is there an octave api
>for writing matlab4.x file-formats?
>I actually looked into the $octave/src/
>but unfortunately it contains lots of functions and data-types 
>I don't have in my C-routine.
>Thanks for your help 
>bye daniel

You can find the mat4 file format description in the docs for mat4 or
in the attachment (mat2.txt). With this you should be able to write
your own API which can look similar to the classes contained in
mat5.txt (untested).

If you want to use the "API" contained in octave you will run into
problems, but it's not impossible. You have to link your C-routine
(preferably C++) against the octave class libraries (after including
the appropriate octave-headers). The problem is, the functions needed
for reading and writing matlab files are not exported.

So additionally, you have to use a modified where you have
to export the functions needed for loading and saving mat files and
link your application against this e.g. After doing
this you are even able to read/write octave_value_lists from/to mat4
files. Take a look at the sources in to see how I've done

Now a suggestion to the octave authors: would it be possible to include
two additional methods to the octave_value_list like
octave_value_list::save( char * fname ) and octave_value_list::load(
char * fname ) in one of the next octave releases? I think this doesn't
take too much time and would help a lot of people.

Best regards,
Erich Schneider

Erich Schneider, Dipl.-Phys.     | address@hidden
Neurologische Forschung          | address@hidden
Ludwig-Maximilians-Universit"at  | 
Klinikum Grosshadern, M"unchen   | Fax: +49,89,70906,101

Description: Binary data

reply via email to

[Prev in Thread] Current Thread [Next in Thread]