Statalist The Stata Listserver


[Date Prev][Date Next][Thread Prev][Thread Next][Date index][Thread index]

st: RE: plot the deterministc frontier


From   "Scott Merryman" <[email protected]>
To   <[email protected]>
Subject   st: RE: plot the deterministc frontier
Date   Fri, 17 Feb 2006 13:21:33 -0600

You could use -twoway function- to plot the frontier.

The example below plots, for the first two observations, the frontier
(assuming a Cobb-Douglas production function), and the input isoquant and
displays the output-oriented and input-oriented measures of technical
efficiency.

Scott

webuse greene9,clear
frontier lnv lnk lnl
predict xb,xb
gen y = exp(xb)

forv i = 1/2 {
local lab = `=labor[`i']'
local min = 1
local max = `lab' + `lab'/5
local eff_labor =
((value[`i'])/(exp(_b[_cons])*(`=capital[`i']'^_b[lnk])))^(1/_b[lnl])

twoway function y = exp(_b[_cons])*(`=capital[`i']'^_b[lnk])*x^_b[lnl],
range(`=`min'' `=`max'') ///
|| scatteri `=value[`i']' `=labor[`i']' , msize(medlarge) name(output`i',
replace) mc(blue) ///
|| pcarrowi `=value[`i']' `=labor[`i']' `=value[`i']' `eff_labor' ,
mcolor(blue)  lc(blue) ///
mlabcolor(blue) msize(medium) barbs(medium) ///
|| pcarrowi `=value[`i']' `=labor[`i']' `=y[`i']' `=labor[`i']' ,
legend(off) ///
msize(medlarge) title(Input and Output Oriented Measure of Efficiency)
subtitle(Capital Fixed) ///
ylabel(, angle(0)) ytitle(Output) xtitle(Labor) mcolor(blue)  lc(blue)
msize(medium) barbs(medium)

local cap = `=capital[`i']'
local range_cap = `cap' + `cap'/5
local eff_capital =
((value[`i']/exp(_b[_cons]))/((labor[`i']/capital[`i'])^_b[lnl]))^(1/(_b[lnl
] + _b[lnk]))
local eff_labor = (labor[`i']/capital[`i'])*`eff_capital'

twoway function y = (`=value[`i']'/(exp(_b[_cons])*x^_b[lnk]))^(1/_b[lnl]),
range(1 `=`range_cap'') ///
|| scatteri `=labor[`i']' `=capital[`i']' ,name(input`i', replace) mc(blue)
/// 
|| pcarrowi `=labor[`i']' `=capital[`i']' `=`eff_labor'' `=`eff_capital''  ,
lw(medthick)  ///
mcolor(blue)  lc(blue)  msize(medium) barbs(medium)  legend(off)  ///
ylabel(, angle(0)) ytitle(Labor) xtitle(Capital) title(Input Oriented
Measure of Efficiency)

}


-----Original Message-----
> From: [email protected] [mailto:owner-
> [email protected]] On Behalf Of Viktor Slavtchev
> Sent: Monday, February 13, 2006 2:49 AM
> To: [email protected]
> Subject: st: plot the deterministc frontier
> 
> hello dear statalisters,
> is there some easy way to plot the deterministic frontier after using
> -frontier-?
> thanks for any help
> viktor
> 


*
*   For searches and help try:
*   http://www.stata.com/support/faqs/res/findit.html
*   http://www.stata.com/support/statalist/faq
*   http://www.ats.ucla.edu/stat/stata/



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