Stata The Stata listserver
[Date Prev][Date Next][Thread Prev][Thread Next][Date index][Thread index]

Re: st:predict in xtfrontier

From   "Vidya Mahambare" <>
To   <>
Subject   Re: st:predict in xtfrontier
Date   Wed, 26 Nov 2003 10:29:23 +0000

Thanks to Nick Cox for suggestion.Very helpful indeed.
I would like to look at how efficiency has changed in each sector over time,
hence the year came into the picture.


>>> 25/11/03 3:20 PM >>>
No programming needed. 

egen maxte = max(te), by(sector) 
gen relte = te/maxte 

If no values of -te- were missing, you 
could do it in one 

bysort sector (te) : gen relte = te/te[_N] 

However, the -sort- in -bysort- would 
push any missings in -te- to the end, 
so the -egen- route is safer.  


P.S. I don't know where year enters into 
this, due to ignorance of frontier models. 
I stopped studying economics in 1969. But 
the basic approach here can be refined. 

Vidya Mahambare
> I have now created estimates for TE for each sector 
> following Nick Cox's
> suggestion. I would now like to compute TE for  each firm 
> in a sector relative
> to maximum TE in that sector in a particular year. 
> I am not sure how to proceed, mainly due to the lack of 
> understanding of
> programming. 

*   For searches and help try:

*   For searches and help try:

© Copyright 1996–2023 StataCorp LLC   |   Terms of use   |   Privacy   |   Contact us   |   What's new   |   Site index