Page 1 of 1
Count within Cross-sectional identifiers
Posted: Wed Jun 17, 2009 8:27 am
by tchaithonov
Hi Everybody,
I am trying to do a count of the number of cross sections within my pooled OLS model, and I have "market" as my cross-section ID. How should I do it? Please share your thoughts. Thanks.
Tchaithonov
Re: Count within Cross-sectional identifiers
Posted: Wed Jun 17, 2009 9:14 am
by EViews Gareth
Assuming you're working with a Pool object, you can do:
scalar count = poolname.@ncrossest
where poolname is the name of your pool object.
Re: Count within Cross-sectional identifiers
Posted: Wed Jun 17, 2009 10:11 am
by tchaithonov
I am actually not working on a pool object. I have a stacked dataset with a cross section identifier (mkt) and a time series identifier (week), and now I have set it up as a balanced panel. As I was told, I should be running panel (so, using LS instead of POOL) for the large numbers of cross sections I have. So, my series are not "pooled" together. Is there still a way to do so? Please let me know. Thanks.
Re: Count within Cross-sectional identifiers
Posted: Wed Jun 17, 2009 10:22 am
by EViews Gareth
Yep, you can use:
equation_name.@ncross
Re: Count within Cross-sectional identifiers
Posted: Wed Jun 17, 2009 10:37 am
by tchaithonov
I tried it, but eviews keeps complaining that it has a syntax error for the @ncross line. I could find @ncoef and @regobs in the manual/help file, but not @ncross.
Re: Count within Cross-sectional identifiers
Posted: Wed Jun 17, 2009 10:49 am
by EViews Gareth
What's the version number and build date of your copy of EViews (both available from Help->About EViews)
Re: Count within Cross-sectional identifiers
Posted: Wed Jun 17, 2009 10:59 am
by tchaithonov
I tried this on an Eviews 6 Apr 20 2007 build and an Eviews 5 Jan 20 2006 build.
Re: Count within Cross-sectional identifiers
Posted: Wed Jun 17, 2009 11:05 am
by EViews Gareth
Re: Count within Cross-sectional identifiers
Posted: Wed Jun 17, 2009 11:19 am
by tchaithonov
Neat! It works now. Thanks for your help.