Herfindahl-Hirschman index calculation in Eviews

For econometric discussions not necessarily related to EViews.

Moderators: EViews Gareth, EViews Moderator

emelia67
Posts: 13
Joined: Wed Apr 02, 2014 2:52 pm

Herfindahl-Hirschman index calculation in Eviews

Postby emelia67 » Wed Apr 02, 2014 3:06 pm

I was wondering if Eviews could calculate HHI across 30 banking jurisdictions containing 267 banks over a 12 year period using the total assets of the respective banks as their market shares. If it could be done how do I proceed.

Many thanks.
Last edited by emelia67 on Thu Apr 03, 2014 6:21 am, edited 1 time in total.

trubador
Did you use forum search?
Posts: 1520
Joined: Thu Nov 20, 2008 12:04 pm

Re: Herfindahl-Hirschman index calculation in Eviews

Postby trubador » Thu Apr 03, 2014 1:27 am

You can easily calculate HH index in EViews:

Code: Select all

'Example taken from 'http://en.wikipedia.org/wiki/Herfindahl_index 'Create a workfile wfcreate u 16 'Create the series to hold shares series shares 'Assume that 10% of output is divided among 10 equally sized producers smpl 7 @last shares = 0.01 'Case 1: All six firms produce 15% each smpl 1 6 shares = 0.15 smpl @all scalar Hindex1 = @sumsq(shares) 'Case 2: One firm produces 80% while the five others produce 2% each smpl 1 1 shares = 0.80 smpl 2 6 shares = 0.02 smpl @all scalar Hindex2 = @sumsq(shares) 'Ideal case: Each firm would have a share of 1/N scalar Hindex = 16*(1/16)^2
In your case, however, you may need to structure your data as Panel. Following example will give you the idea:

Code: Select all

'Create a panel workfile !first = 2002 !last = 2013 !banks = 267 wfcreate(wf=banks, page=data) a !first !last !banks 'Your series would have the actual values series shares = 1/!banks 'Create a table to summarize results table(13,2) Hindex Hindex(1,1) = "Years" Hindex(1,2) = "HH_index" !nperiods = !last-!first+1 'Compute the index for each year for !i = 1 to !nperiods smpl !first+!i-1 !first+!i-1 Hindex(!i+1,1) = @str(!first+!i-1) Hindex(!i+1,2) = @sumsq(shares) next smpl @all

emelia67
Posts: 13
Joined: Wed Apr 02, 2014 2:52 pm

Re: Herfindahl-Hirschman index calculation in Eviews

Postby emelia67 » Thu Apr 03, 2014 6:20 am

Many thanks, but I find it a bit difficult to get my head round it. Are the two boxes alternative methods to do it? Would be glad if you could come a bit clearer. Again for your information my data set is panel.

trubador
Did you use forum search?
Posts: 1520
Joined: Thu Nov 20, 2008 12:04 pm

Re: Herfindahl-Hirschman index calculation in Eviews

Postby trubador » Thu Apr 03, 2014 6:42 am

You can work on the second code.

emelia67
Posts: 13
Joined: Wed Apr 02, 2014 2:52 pm

Re: Herfindahl-Hirschman index calculation in Eviews

Postby emelia67 » Thu Apr 03, 2014 4:08 pm

Fine, I'll use the second code. But could you walk me through the procedure step by step, please. As it is I cannot make any sense of the numbers, the exclamation signs, etc, etc. Would be glad if you could tell me what each means. The attached is the data set in question - the series (column) BSIZE is the total assets per bank in a country per year which I use as a proxy for the market share which I calculate as its ratio to the total assets for all the banks in a country multiplied by 100.

trubador
Did you use forum search?
Posts: 1520
Joined: Thu Nov 20, 2008 12:04 pm

Re: Herfindahl-Hirschman index calculation in Eviews

Postby trubador » Fri Apr 04, 2014 12:12 am

EViews has very nice pedagogical learning resources. See, for instance, Help-->EViews Illustrated. You can then have a look at the manuals and search the forum if you need further help.

emelia67
Posts: 13
Joined: Wed Apr 02, 2014 2:52 pm

Re: Herfindahl-Hirschman index calculation in Eviews

Postby emelia67 » Fri Apr 04, 2014 1:49 am

I wonder if that manual specifically talks about the calculation of HHI. If it does and I have not sighted it could you please for example sign-post it to me, for example the precise page where I can have help.

Thanks.

trubador
Did you use forum search?
Posts: 1520
Joined: Thu Nov 20, 2008 12:04 pm

Re: Herfindahl-Hirschman index calculation in Eviews

Postby trubador » Fri Apr 04, 2014 2:31 am

Of course not. Those sources will guide you through the steps necessary for understanding and using the software for such custom needs.

emelia67
Posts: 13
Joined: Wed Apr 02, 2014 2:52 pm

Re: Herfindahl-Hirschman index calculation in Eviews

Postby emelia67 » Mon Apr 07, 2014 7:59 am

In order not to waste time raking through the pages could you please point me to the pages for such custom needs.

Thanks

EViews Gareth
Fe ddaethom, fe welon, fe amcangyfrifon
Posts: 13604
Joined: Tue Sep 16, 2008 5:38 pm

Re: Herfindahl-Hirschman index calculation in Eviews

Postby EViews Gareth » Mon Apr 07, 2014 10:22 am

Page 415 of EViews Illustrated PDF.
Page 689 of EViews 8 Command Reference PDF.
Page 887 of EViews 8 Object Reference PDF.

emelia67
Posts: 13
Joined: Wed Apr 02, 2014 2:52 pm

Re: Herfindahl-Hirschman index calculation in Eviews

Postby emelia67 » Mon Apr 07, 2014 10:35 am

Many thanks, Gareth for your kindness!

emelia67
Posts: 13
Joined: Wed Apr 02, 2014 2:52 pm

Re: Eviews regression output Warning

Postby emelia67 » Tue Apr 08, 2014 3:52 am

In a panel estimation using white cross section as a coefficient covariance method for robust SEs what does Eviews mean when it warns thus: WARNING: estimated coefficient covariance matrix is of reduced rank .

EViews Glenn
EViews Developer
Posts: 2682
Joined: Wed Oct 15, 2008 9:17 am

Re: Herfindahl-Hirschman index calculation in Eviews

Postby EViews Glenn » Tue Apr 08, 2014 8:36 am

That your coefficient covariance matrix is singular.
One possibility is that you have fewer periods than the number of coefficients.

emelia67
Posts: 13
Joined: Wed Apr 02, 2014 2:52 pm

Re: Herfindahl-Hirschman index calculation in Eviews

Postby emelia67 » Tue Apr 08, 2014 2:44 pm

Ok Glenn, either way does that then mean the regression results aren't reliable? And if so what could be the best solution?


Return to “Econometric Discussions”

Who is online

Users browsing this forum: No registered users and 2 guests