Am 27.05.2014 02:56, schrieb Allin Cottrell:
On Mon, 26 May 2014, Sven Schreiber wrote:
Well, "obs" is a reserved word in gretl while "date" is not.
I thought "date" was a synonym for "obs" for the purposes of
importing,
but apparently I mixed things up.
Normally that wouldn't matter but in this case it does because
the
hugely gappy Maddison data are not recognized by gretl as any sort
of time series so gretl is apparently trying to read the first
column as data.
But shouldn't gretl in this case tell the user that it doesn't recognize
the "obs" values as periods, instead of complaining about the header?
> I also have to rename many many variables in the xls file before
> gretl accepts them, and I think this is really not the optimal way
> to handle this because it's very time-consuming and dull; there
> should be some automagic "mangling" of the names by gretl [...]
I see that Stata has infinite patience with silly-buggers column
headings and in CVS I've made a move in that direction. But I need
to rant just a little: I suppose the data are carefully done, but
the column headings look as if they've been added by a total
computer illiterate with the attitude "I don't care; if anyone
really wants to make sense of this they'll find a way".
Rant granted. But OTOH I think one has to concede that with this stuff
Excel sets a kind of standard that people come to expect of other
software as well. It's like blanks in file names; I hate them and try to
educate others to hate them as well, but in practice on Windows one has
to admit that they usually just work.
> Then I tried to treat the whole thing as a (country) panel
> structure -- but I'm noticing (for the first time although it must
> have been there for ages) that when I choose "new dataset" from
> the menu, the dialog forces on me the detour to specify the
> overall number of obs (anybody got a calculator ready?)
Yes, on the gretl toolbar ;-)
Yep, but I still see the potential to roll several dialogs into one there.
> Another suggestion: why not allow the use of a time index
variable
> for time series the same way that index variables are allowed for
> panels?
Maybe, but this is not needed for any ordinary time series.
Right, the need only appeared with these funny series.
Importing these data is not trivial since although they have a time
dimension they do not resemble any ordinary time-series. I have to
wonder what the advantage is in having them recognized as a "time
series" of sorts; I can't imagine that any time-series methods could
be applied to them.
All I wanted to do is to plot them, for example in a bar graph (so that
NAs really don't get plotted or connected). The point is that I use
gretl often only as a data manager for things like transformations or
plots, without doing econometrics on the data, because gretl is usually
very good at it.
In the end I used Excel which I don't like much for plotting, and it
also did not work 100%, but at least I got something.
Anyway, you can get them to appear as annual data in gretl as
follows. I began by opening the file in gnumeric and exporting it as
text, with all fields quoted. One could use ssconvert. You then have
to fix a few variable names (and add a couple of missing ones) -- or
use current CVS to have the varnames handled automatically. In
addition I gave the first column a heading of "myear" so that gretl
wouldn't try to interpret it as time. Then,
...
I really appreciate your efforts, you really don't have to provide
tailor-made solutions to questions like these. When I report these
problems it's to extend gretl in the future, not (usually) to get the
work done for me. Anyway, since I wanted to plot the data, I could have
imported them in a matrix like you did and then use the built-in matrix
plotting feature of the 'gnuplot' command. I'll try this.
Thanks!
Sven