Notice: On March 31, it was announced that Statalist is moving from an email list to a forum. The old list will shut down on April 23, and its replacement, statalist.org is already up and running.

 From "Chong, Qi Lin Andrew" To "statalist@hsphsun2.harvard.edu" Subject RE: st: Re: Finding initial feasible values for xtfrontier, ti cost version, please help! Date Fri, 26 Mar 2010 14:32:26 -0400

```Hi all, many thanks to Rogelio and Scott for the tips about Winbugs and xtfrontier in STATA.

To Scott, for the xtfrontier, would you know if i am using a translog function model of the form:

xtfrontier logexpense logsum logpdep logpop logsum2 logdeppop logsumdep logsumpop, ti cost difficult from(b0, copy)

logexpense = cost of firm
logsum = total output of firm
where logpdep = price of deposits (an input)
logpop = price of operational input
logsum2 = logsum*logsum
logdepop = price of dep*price of operational input
logsumdep = logsum*logdep
logsumpop = logsum*logpop

where I basically list all outputs, all input prices, all outputs interacted all outputs interacted with each other (in pairs), listing all input prices interacted with each other (in pairs), and then all possible pairings between outputs and input prices.

1) Should I put all the variables after logsum2 into the original regression as well?
2) How did you get the value of 1 of the -mu term?
3) I've run the specifications with the addition of 1 and with all the variables above put into the original regression eqn to find initial values and into the xtfrontier command. I have been receiving equal log likelihoods of the same value (and "backed up) for many iterations. Should I just let it stay running? Is there anything I can do if I fail to get a solution that converges?

Thanks a lot for your help Scott.

Andrew

________________________________________
From: owner-statalist@hsphsun2.harvard.edu [owner-statalist@hsphsun2.harvard.edu] On Behalf Of Scott Merryman [scott.merryman@gmail.com]
Sent: Friday, March 26, 2010 7:28 AM
To: statalist@hsphsun2.harvard.edu

On Thu, Mar 25, 2010 at 4:27 PM, Chong, Qi Lin Andrew
<qchong@middlebury.edu> wrote:
> Hello all,
>
> I am running an xtfrontier on commercil banks, with the cost specification on stata. I have found David Drukker's guide to finding the initial value for a frontier eqn v. helpful, but he uses the normal specification (production and not cost) and also the example is not in panel form.
>
> http://www.stata.com/statalist/archive/2003-05/msg00650.html
>
> QUERY1) My question is how to replicate the above steps and find the appropriate inital values for xtfrontier, ti cost. I'm not sure how it changes the format above, in terms of running a straightforward regression, but using
>
> regress logexpense logsum logpdep logpop logdeppop logsumdep logsumpop,
> matrix b0 = e(b), ln(e(rmse)^2) , .1
>
> I am left with one missing variable and get the error message
>
> initial vector: matrix must be dimension 10
>
<snip>

With -xtfrontier , ti- there are 3 additional parameters: -mu-,
-lnsigma2-, and -ilgtgamma- and value must be given for each of them.

For example:

. webuse xtfrontier1

. qui reg lnwidgets lnmachines lnworkers

. matrix b0 = e(b), 1, ln(e(rmse)^2) , .1

. xtfrontier lnwidgets lnmachines lnworkers, ti  from(b0, copy) nolog

Time-invariant inefficiency model               Number of obs      =       948
Group variable: id                              Number of groups   =        91

Obs per group: min =         6
avg =      10.4
max =        14

Wald chi2(2)       =    661.76
Log likelihood  = -1472.6069                    Prob > chi2        =    0.0000

------------------------------------------------------------------------------
lnwidgets |      Coef.   Std. Err.      z    P>|z|     [95% Conf. Interval]
-------------+----------------------------------------------------------------
lnmachines |   .2904551   .0164219    17.69   0.000     .2582688    .3226415
lnworkers |   .2943332   .0154352    19.07   0.000     .2640807    .3245857
_cons |   3.030971    .144102    21.03   0.000     2.748536    3.313406
-------------+----------------------------------------------------------------
/mu |   1.125531    .648041     1.74   0.082    -.1446056    2.395668
/lnsigma2 |    1.42203   .2673122     5.32   0.000     .8981073    1.945952
/ilgtgamma |    1.13875   .3563081     3.20   0.001      .440399    1.837101
-------------+----------------------------------------------------------------
sigma2 |   4.145526    1.10815                      2.454952    7.000293
gamma |   .7574501   .0654607                      .6083541    .8626055
sigma_u2 |   3.140029   1.107447                       .969473    5.310585
sigma_v2 |   1.005497   .0484144                      .9106065    1.100387
------------------------------------------------------------------------------

Scott

*
*   For searches and help try:
*   http://www.stata.com/help.cgi?search
*   http://www.stata.com/support/statalist/faq
*   http://www.ats.ucla.edu/stat/stata/
*
*   For searches and help try:
*   http://www.stata.com/help.cgi?search
*   http://www.stata.com/support/statalist/faq
*   http://www.ats.ucla.edu/stat/stata/
```