title: How come I get this logistic regression error in glm/glm2 if I don't exhibit linear separation in my data?
body: <p>I started running into the error (converted from warning):</p>
  
  <pre><code>glm.fit (or glm.fit2): fitted probabilities numerically 0 or 1 occurred
  </code></pre>
  
  <p>I found this link referencing linear separation of data:</p>
  
  <p><a href="https://stat.ethz.ch/pipermail/r-help/2008-March/156868.html" rel="nofollow">[R] glm.fit: "fitted probabilities numerically 0 or 1 occurr</a></p>
  
  <p>So I tried hunting through the data and found a small reproducible example from a small subset of the data (both glm and glm2) where I don't actually see the linear separation and yet I get the error:</p>
  
  <pre><code>response = c(0,1,0,1,0,0,0,0,0,0)
  dependent = c(133,571,1401,4930,3134075,44357054,1718619387,1884020779,8970035092,9392823637)
  foo = data.frame(y=response,x=dependent)
  glm(y ~ x, family=binomial, data=foo)
  </code></pre>
  
  <p>I can avoid the issue by transforming the dependent via <code>log(x+1)</code>, however, this is monotonic and doesn't alter the ordering so I'm not sure why that helps and whether I should be doing so. The dependents are "microseconds since the last time some event happened" which is why some values can be large. I tried turning it into a two level factor of (recent, not recent) but that loses information and underperforms the raw values.</p>