[Gretl-users] error with null list

Sven Schreiber svetosch at gmx.net
Thu Jan 4 07:16:02 EST 2007


Riccardo (Jack) Lucchetti schrieb:

> 
> Ok, I see what you mean now. If I'm not mistaken, your idea is to use the
> include statement to bring back into gretl some objects (presumably matrices),
> previously generated outside by a python script.

exactly

> 
> Allin and I had started thinking about a similar mechanism some months ago:
> the only difference was that I had thought of using Ox instead of python. I
> even managed to write a working prototype of an exchange mechanism that worked
> as follows.

Indeed sounds very similar. Of course python/numpy is truly free, unlike
ox. (BTW, check out www.scipy.org) OTOH I would also be interested in
making a gretl frontend to Ox's Ssfpack (Kalman filter) this way. Or do
you know a truly free package comparable to Ssfpack? (But this is
getting OT...)

> 
> First, let's define the concept of a "binary bundle". A binary bundle is a
> binary file which contains one or more objects. An object can be
> 
> 1) a scalar
> 2) a matrix
> 3) a dataset
> 4) a model
> 

I would also add: 5) some text, comment, etc.

Why does it have to be binary? Human-readable is an advantag IMO. Unless
you have tons of data, but I doubt you would be using gretl then (no
offense...).

> Now, everything that's needed to shuffle stuff to/from gretl is the ability,
> by gretl and the helper application (Ox, python, R, scilab, whatever) to read
> and write bundles. I had come to the point of writing an Ox class for this,
> and the corresponding C functions, which we never merged into gretl. But if
> you think that you can write a corresponding set of functions in python, then
> we wouldn't need to mess with run/include. 

If I understand you correctly, then yes I can do the helper app side and
bundle reading/writing in python. So if a 'bundle_read' facility is much
more simpler than enabling 'include/run' in gretl functions, fine with me.

> 
> I think this would provide a very neat way to do what I assume you need.
> However, the coding effort is definitely not trivial. Could we schedule this
> for 1.7.0?

What if you start out just with the ability to read in "bundles" with
genr/matrix/print commands (for scalars/matrices/text). Essentially just
opening the file and executing the literal contents as if the user typed
them in directly. like a limited version of 'run'. That wouldn't be so
difficult, would it?

(Should we take this off the user list? but keep me cc-ed please, or
maybe I should subscribe to gretl-devel...)

-sven





More information about the Gretl-users mailing list