On 16/02/13 17:01, Sven Schreiber wrote:
Am 16.02.2013 16:21, schrieb Allin Cottrell:
> On Fri, 15 Feb 2013, Ignacio Diaz-Emparanza wrote:
>
>> BTW, when you ask gretl to add "periodic dummies" in such a way the
names of
>> the dummy variables depend on the seasonal periodicity, i.e. if the data are
>> quarterly the dummies are dq1,..., dq4, if the data are monthly they are
>> dm1,..., dm12 if the seasonal periodicity is greather than 12 the dummies are
>> dummy_1,..., dummy_99 and then dummy100, dummy101, etc
>>
>> At the risk of introducing another backward incompatible change, I would
>> suggest our dear developers that a unique name should be used for the
>> seasonal dummies independently on the periodicity. And I propose to use d1,
>> d2, ....
> I don't have any objection to that, other than the backward
> incompatibility. Any others have thoughts on the matter?
>
Ignacio, could you explain the advantages? Or the other way around, the
disadvantages of having different names for different periodicities?
1) It is
easier for the user to have a unique name.
2) For a user who wants to use the seasonal dummies inside a function it
is really uncomfortable not knowing beforehand what are their names, so
having to use always an ugly intermediate function like this below while
changing to a unique name may avoid it:
<hansl>
function list seasdum (void)
list deterministic = null
genr dummy
if ($pd=4)
list deterministic += dq1 dq2 dq3
elif ($pd=12)
list deterministic += dm1 dm2 dm3 dm4 dm5 dm6 dm7 dm8 dm9 dm10 dm11
else
scalar spd1=$pd-1
loop i=1..spd1 --quiet
if (i<100)
list deterministic += dummy_$i
else
list deterministic += dummy$i
endif
endloop
endif
return deterministic
end function
nulldata 100
#Quarterly data
setobs 4 1:1 --time-series
list sdum=seasdum()
list sdum --print
nulldata 100
#Monthly data
setobs 12 1:1 --time-series
list sdum=seasdum()
list sdum --print
nulldata 1000
#Hourly data
setobs 24 1:1 --time-series
list sdum=seasdum()
list sdum --print
nulldata 1000
#A rather extreme case:
#Weekly periodicity with hourly data
setobs 168 1:1 --time-series
list sdum=seasdum()
list sdum --print
</hansl>
I see now from Jack's response that the function might be made now much
simpler using
q=$obsminor
list D=dummify(q)
and if $obsminor is allowed as a parameter of 'dummify' in only one line:
list D=dummify($osbminor)
(But Jacks's example does not work for $pd=168)
Actually, if the seasonal dummies business were touched, I would
propose
to think also about covering centered seasonal dummies, as gretl already
does in the VECM case.
I also support this.
--
Firma Arista
*Ignacio Díaz-Emparanza*
Zuzendaria/Director
ignacio.diaz-emparanza(a)ehu.es <mailto:ignacio.diaz.emparanza@ehu.es>
94 6013732
*EKONOMIA APLIKATUA III SAILA (EKONOMETRIA ETA ESTATISTIKA)/
DEPARTAMENTO DE ECONOMÍA APLICADA III (ECONOMETRÍA Y ESTADÍSTICA)
UPV/EHU*
Avda. Lehendakari Aguirre, 83 | 48015 BILBAO
*T.: +34 946013740* | *F.: +34 946013754*
*www.ea3.ehu.es* <
http://www.ea3.ehu.es>
ERNE! Baliteke mezu honen zatiren bat edo mezu osoa legez babestuta
egotea. Mezuak badu bere hartzailea. Okerreko helbidera heldu bada
(helbidea gaizki idatzi, transmisioak huts egin) eman abisu igorleari,
korreo honi erantzunda. Kontuz! Mezua ez bada zuretzat, ez erabili, ez
zabaldu beste inori, ez kopiatu eta ez baliatu.
¡ATENCIÓN! Este mensaje contiene información privilegiada o confidencial
a la que sólo tiene derecho a acceder el destinatario. Si usted lo
recibe por error le agradeceríamos que no hiciera uso de la información
y que se pusiese en contacto con el remitente.
E-mail hau inprimatu baino lehen egiaztatu inprimatzeko beharra.
Antes de imprimir este e-mail piense bien si es necesario hacerlo.