title: R: Error in optim - non-finite value supplied
body: <p>I am trying to perform a beta regression on R using the command below:</p>
  
  <pre><code>   DV4.25112013.v2_logit &lt;- betareg(DV4.25112013.v2 ~ 
                                    (Bcorp.Geographic.Proximity +    
                                     Dirty.Industry)^2, data=df, na.action=na.omit) 
  </code></pre>
  
  <p>but it gives me the following error:</p>
  
  <pre><code>Error in optim(par = start, fn = loglikfun, gr = gradfun, method = method,  : 
  non-finite value supplied by optim
  </code></pre>
  
  <p>My Dependent variable data set is showing below:</p>
  
  <pre><code>9.251774e-04 1.226072e-02 9.608363e-04           NA           NA 1.768424e-03 4.506405e-04               
            NA 2.813550e-03 6.301197e-03           NA 2.584045e-02 1.298593e-03 3.279355e-04 
  8.840719e-03 1.479985e-04 1.139517e-03 1.261994e-02 1.054185e-02 2.972740e-02 7.572882e-03           
            NA           NA 2.398657e-02 4.605694e-03           NA           NA 6.879709e-03           
            NA 1.177712e-02 4.685408e-02 2.735896e-04           NA 7.779318e-03 1.096625e-05 
  8.366171e-04 2.988228e-04 4.226364e-03 4.600874e-04 5.070094e-03 1.004572e-01           NA 
  7.904296e-03 1.229791e-04           NA 1.072013e-04 3.022147e-03 6.271264e-03           NA           
            NA 2.714173e-02 5.537466e-04           NA 5.214199e-04 6.207046e-03           NA           
            NA 6.945933e-04           NA 1.376983e-03 7.183495e-04           NA           NA      
  4.542490e-05 1.891985e-02 7.712977e-03 6.184493e-04 3.098408e-03 6.969552e-03           NA 
  1.480573e-04 1.029175e-02 1.232377e-04           NA 6.540225e-03 3.856216e-02           NA    
  1.769285e-00           NA 5.681399e-04 5.862517e-03 8.520513e-03 2.159825e-04 7.045354e-04 
  1.129759e-02 5.876718e-04           NA 1.780352e-03 1.071973e-04           NA 1.444186e-02
            NA 1.532570e-02           NA           NA 3.265149e-02 4.457103e-02           NA 
  1.163361e-02 1.372521e-02 2.645904e-03 6.539674e-05           NA 9.671331e-03           NA 
  1.540429e-03           NA 4.772404e-04 2.452567e-03 4.511210e-03           NA           NA 
  7.728757e-03 3.087052e-03 4.169794e-03 1.298330e-03           NA
  </code></pre>
  
  <p>why am I getting this error, and how can I solve this issue?</p>
  
  <p>thank you</p>