Possible Duplicate:
How should I transform non-negative data including zeros?

I want to perform log transformation regression in R tool but the problem is that I don't know how to handle situations when data contains 0 since log 0 is infinite... Please help..

  • 1
    $\begingroup$ Take a look here stats.stackexchange.com/questions/1444/… . But probably you should convert them to non-zero values somehow. $\endgroup$ Commented Jan 6, 2013 at 5:50
  • $\begingroup$ Well if i were you i'd try to find another way. What phenomenon are you trying to describe? Is the log-transformation really needed? $\endgroup$
    – Davide
    Commented Jan 6, 2013 at 10:00
  • $\begingroup$ There is no best method to handle such situation. However, you can use log(x+c) where c is a small number or log(x+x/2). Also, you can try Poisson, beta or gamma distribution as an alternative. $\endgroup$ Commented Mar 22, 2016 at 9:48


Browse other questions tagged or ask your own question.