title: Error in backward and stepwise selection in R
body: <p>I use Cox regression to model survival data.
  My dataset has 345 observations and 78 events. The number of predictors in the Cox model is 124. All 124 variables are continuous
  Now, I want to do variable selection.The forward selection works fine. However, the stepwise and backward selection give the following error:</p>
  
  <pre><code>    Error in coxph.wtest(fit$var[nabeta, nabeta], temp, control$toler.chol) : 
      NA/NaN/Inf in foreign function call (arg 3)
  </code></pre>
  
  <p>Here is a sample of the code (unfortunatelly I cannot provide any data):</p>
  
  <pre><code>    fit &lt;- coxph(Surv(time,Status) ~ .  , data=data1)
      final &lt;- step(fit, direction="both")
  </code></pre>
  
  <p>Anyone knows what is the problem/what is the meaning of this error?
  Is it the number of predictors maybe?</p>