Announcement

Collapse
No announcement yet.
X
  • Filter
  • Time
  • Show
Clear All
new posts

  • Stata beginner: code for stochastic production frontier model (BC92)

    *Caveat: I am a PhD student still new to Stata, and I have only a moderate level of statistics experience.

    I am estimating the production frontier and firm inefficiency for a cross-sectional (agricultural) dataset with a Cobb Douglas functional form using the BC92 "tvd" model with three inputs to the frontier model and 4 exogenous inputs to the inefficiency model. According to my supervisor, the eta should be set to zero and half-normal distribution specified for the inefficiency error component.

    I am quite uncertain as to which frontier command to start with: xtfrontier, sfpanel, sfmodel, sfcross? And from there, I am somewhat lost...

    I would be extremely grateful if another [more experienced!] user could please share the lines of code to estimate the frontier model, the inefficiency model and predict inefficiency scores.
    I have read the two existing posts regarding the BC92 model and noted their advice, but I need more comprehensive assistance. Thank you in advance!

  • #2
    Since you only have cross-sectional data you will need to use -froniter- or Federico Belotti et al -sfcross-. Something like:
    Code:
    frontier lnoutput lnk lnl lnm, vhet(x1 x2 x3 x4)
    For example:
    Code:
    . clear
    
    . webuse frontier1
    
    . //techinical efficiency as function of firm size
    . frontier lnoutput lnlabor lncapital, uhet(size)
    
    Iteration 0:   log likelihood = -1508.3692  
    Iteration 1:   log likelihood = -1505.0122  
    Iteration 2:   log likelihood = -1505.0067  
    Iteration 3:   log likelihood = -1505.0067  
    
    Stoc. frontier normal/half-normal model                 Number of obs =    756
                                                            Wald chi2(2)  =   8.90
    Log likelihood = -1505.0067                             Prob > chi2   = 0.0117
    
    ------------------------------------------------------------------------------
        lnoutput | Coefficient  Std. err.      z    P>|z|     [95% conf. interval]
    -------------+----------------------------------------------------------------
    lnoutput     |
         lnlabor |   .6709033   .2401539     2.79   0.005     .2002103    1.141596
       lncapital |   .6079313   .5638755     1.08   0.281    -.4972443    1.713107
           _cons |   .2044104   3.282278     0.06   0.950    -6.228736    6.637557
    -------------+----------------------------------------------------------------
    lnsig2v      |
           _cons |  -.2280262   .1953434    -1.17   0.243    -.6108922    .1548398
    -------------+----------------------------------------------------------------
    lnsig2u      |
            size |  -.0003938   .0001977    -1.99   0.046    -.0007812   -6.43e-06
           _cons |   2.769215   .4032404     6.87   0.000     1.978878    3.559551
    -------------+----------------------------------------------------------------
         sigma_v |   .8922463   .0871472                      .7367946    1.080496
    ------------------------------------------------------------------------------
    
    . //test for constant returns to scale
    . test _b[lnlabor] + _b[lncapital] = 1
    
     ( 1)  [lnoutput]lnlabor + [lnoutput]lncapital = 1
    
               chi2(  1) =    0.21
             Prob > chi2 =    0.6504
    
    . //predict technical efficiency
    . predict te, te

    Comment


    • #3
      Thank you very much, Scott. I will come back to the post once I've run the code, if I have troubleshooting needs. I appreciate your help!

      Comment


      • #4
        Hello, I'm a PhD student, and my aim is to estimate technical and allocative inefficiencies using the profit frontier model.
        Profit is my dependent variable, and the independent variables are input costs ( fertiliser cost, irrigation cost, land preparation cost, seed cost). inefficiency variables are the irrigated area, crop type experience ensure the Cobb Douglas profit function, I am using log format for these variables. Cross-section data
        I'm not sure how to estimate technical and allocative efficiency in STATA 16 using a one-step approach.
        Enable GingerCannot connect to Ginger Check your internet connection
        or reload the browserDisable in this text fieldRephraseRephrase current sentence7Log in to edit with GingerĂ—
        Last edited by Anushiya Thanapalan; 30 Nov 2021, 23:36.

        Comment

        Working...
        X