[Date Prev][Date Next][Thread Prev][Thread Next][Date index][Thread index]

st: RE: log of zero

From   "Nick Cox" <>
To   <>
Subject   st: RE: log of zero
Date   Wed, 2 Jul 2008 11:16:04 +0100

Goodness knows. There are many recipes, all of them problematic. "Go out
and measure it again" is the best advice! That divides sciences. In some
it is regarded as self-evident, in others as possibly a strange joke. 

I just want to point out that far being conservative, using a very small
positive value rather than zero creates outliers in terms of log of the
variable in question. Using half the smallest non-zero value observed is
another fudge that is not quite so objectionable. 

For example, consider 0, 1, 2 fudged to 

(1) 2^-10, 1, 2

(2) 0.5, 1, 2. 

Using log base 2 to convenience -- clearly the same principle applies to
any other base -- you can see that logged these come to 

(1) -10, 0, 1

(2) -1, 0, 1 

So far from being minute, any smidgen is a big deal on a log scale. 

Also in the "yes, I thought of that already" category is advice to try
different solutions and see how much difference they make. 

Viktor Slavtchev

I want to estimate production function in logs in order to interpret the

coefficients in terms of elasticities. one of the RHS variables has a 
lot of zero value. in such cases, some people usually add a very small 
value in order to avoid the problem of 'undefined' log of zero. a 
similar issue was discussed some time ago among other things and in a 
quite different context but an interesting alternative suggestion was 
made (which I can't remember anymore). unfortunately, I was not able to 
find this particular thread.
in that sence, any suggestions how to deal with the problem would be 
greatly appreciated

*   For searches and help try:

© Copyright 1996–2017 StataCorp LLC   |   Terms of use   |   Privacy   |   Contact us   |   What's new   |   Site index