Am 01.03.2020 um 02:17 schrieb Allin Cottrell:
On Sat, 29 Feb 2020, Artur Tarassow wrote:
> I would like to add additional time-dimensions (n observations)
for
> each unit in a panel. I've tried to make use of the <dataset addobs>
> command but it does, instead, add a whole new unit:
> Is there a 'clever' way to expand the time-dimension
while leaving the
> unit-dimension untouched?
1) Save your current panel dataset, making sure you have unit and time
variables defined.
2) Using "nulldata", construct a panel that's larger in the time
dimension.
3) Use "join" to bring in the data from the original, saved dataset.
4) Use whatever method you fancy to populate the remaining empty
observations in the time dimension.
Thanks Allin for the workaround, but I tend to think this should become
a feature request - which doesn't say anything about when it would be
implemented, of course. But the workaround could be mentioned in the
ticket there. (Where personally I would use 'append' instead of 'join'
here, but that's not the point.)
(The problem is obviously related to the fact that gretl always uses the
"stacked time series" format internally. Related to that: 'dataset
insobs' is not allowed for panel datasets.)
But I still find it surprising given the behavior of other gretl
functions, so I would propose a documentation like with 'obs': "Note
that the result is invariant to subsampling." And yes, I could insert
that if there are no objections.
thanks
sven