Page 1 of 1
Panel Logit
Posted: Fri Feb 04, 2011 8:09 am
by esperanza
Regards to every member of the forum,
I would be very grateful if someone advises me on how to run a panel logit with EViews5,
I am quite familiar with simple logit, but now I need to run a regression on a panel of six Asian countries in order to create an Early Warning System (EWS) for currency crises prediction. I have monthly data for about 5 years, all of the countries in the sample were actually in crises since 1997, July. As for explanatory variable X, I will take 12-month standart deviation of exchange rate and/or annual change in foreign exchange reserves. As for Y, I am slightly confused, probably merely Y=1 for all months during crisis years (1997-1999), Y=0 in all other cases will be assumed.
The difficulty is that I am confused on how to prepare the data, import and run a regression properly.
The purpose of the regression is similar to the one used by Lestano J. in the attached research paper.
Thank you for any useful help.
Re: Panel Logit
Posted: Sat Feb 05, 2011 9:56 am
by esperanza
please, have a look at the data attached, I am still confused in how to prepare/import it to EViews5,
this urgent, I have deadline next week...
thank you in advance.
Re: Panel Logit
Posted: Sun Feb 06, 2011 6:44 am
by esperanza
have anyone ideas on how to run logit on the panel of 7 countries for 1995:1m-2009:12m? in the file attached above?
Re: Panel Logit
Posted: Sun Feb 06, 2011 9:25 am
by startz
What happens when you read your data into EViews and use the logit command?
Re: Panel Logit
Posted: Sun Feb 06, 2011 11:53 am
by esperanza
Startz, thank you for the reply! When I just try to open my series as an 'Equation', I recieve 'Alpha series in specification [var name] @EXPAND can convert to catagorical dummies' message. This happens in the very beginning so that I cannot even choose the type of regression to be run 'logit'.
Here is the file:
Re: Panel Logit
Posted: Sun Feb 06, 2011 12:09 pm
by startz
Try just entering at the command line
Code: Select all
logit y x1 x2 @expand(categoryVariable)
using your real variables of course.
Re: Panel Logit
Posted: Sun Feb 06, 2011 12:14 pm
by esperanza
should it be as follows:
logit yindo x1indo @expand(x1indo)
it does not help, neither does: logit yindo x1indo @expand(categoryVariable), as you have suggested
Re: Panel Logit
Posted: Sun Feb 06, 2011 12:39 pm
by startz
You have two separate problems. The small one is that your variables are stored as alphas rather than as the usual numeric series. To get started, try
The larger problem is that you probably want all your countries listed in one long variable with a separate variable indicating the country. One manual way to do this is to create a new undated workfile with 7 times 180 observations. Create a new variable x1 and copy and paste each country in order. Same thing for any other variables you have. Then create a new variable countryName that has a unique identifier for each country. All this will be a pain, but probably won't take more than an hour.
Re: Panel Logit
Posted: Sun Feb 06, 2011 10:08 pm
by esperanza
Thank you, startz, for the constructive advice. As I have understood from your post, it is only possible to estimate logit for each separate country for time series data, but no panel logit is available? Another thing I wish to understand is what 'alphas' are. This is the first time I encounter this concept.
Re: Panel Logit
Posted: Mon Feb 07, 2011 8:05 am
by startz
Thank you, startz, for the constructive advice. As I have understood from your post, it is only possible to estimate logit for each separate country for time series data, but no panel logit is available? Another thing I wish to understand is what 'alphas' are. This is the first time I encounter this concept.
No, you can do a panel logit. It's just not built into EViews as an automatic procedure so you're going to have to set it up manually.
Re: Panel Logit
Posted: Mon Feb 07, 2011 9:08 am
by esperanza
Is it a long procedure to set it up manually? what should be done for it, could you please specify.
Re: Panel Logit
Posted: Mon Feb 07, 2011 9:21 am
by startz
The larger problem is that you probably want all your countries listed in one long variable with a separate variable indicating the country. One manual way to do this is to create a new undated workfile with 7 times 180 observations. Create a new variable x1 and copy and paste each country in order. Same thing for any other variables you have. Then create a new variable countryName that has a unique identifier for each country. All this will be a pain, but probably won't take more than an hour.
Re: Panel Logit
Posted: Tue Feb 08, 2011 5:01 am
by esperanza
startz, thank you. As I understood, I should place all countries in a row for each variable, so that I get single 'y' series and separate long time series for each x. now, I think everything is clear, thank you once again for your support, startz!