Hi again,
I've got a discrete nomial variable TEST = 0 or 1 or 2
If I estimate a multinomial model the base is 0.
Now I want to change the reference. What is the best way to do it?
How can I create a new discrete variable that follows the following
specification:
If test=1 then NEW=0
If test=2 then NEW=1
If test=3 then NEW=2
Just switching the directions works with the Gretl command genr NEW=2-TEST
Thanks
Pindar
-----Ursprüngliche Nachricht-----
Von: gretl-users-bounces(a)lists.wfu.edu
[mailto:gretl-users-bounces@lists.wfu.edu] Im Auftrag von Allin Cottrell
Gesendet: Mittwoch, 24. März 2010 16:02
An: walt(a)dataanalyticscorp.com; Gretl list
Betreff: Re: [Gretl-users] creating a dummy variable
On Wed, 24 Mar 2010, Data Analytics Corp. wrote:
I have a time series data set that ranges from 1977Q1 to 2009Q4. I
want
to create a dummy variable for the recession quarters (1980Q1 - 1980Q3,
1981Q3 - 1982Q4, etc.) as defined by the NBER. How do I do this in Gretl?
series dum = (obs>=1980:1 && obs<=1980:3) || \
(obs>=1981:3 && obs<=1982:4)
Allin Cottrell
_______________________________________________
Gretl-users mailing list
Gretl-users(a)lists.wfu.edu
http://lists.wfu.edu/mailman/listinfo/gretl-users