Dear all.
I'm implementing the analysis using the household's income data in 2010-2012.
Since the income data was not normally distributed (and have a wide range), I'd like to do the log-transformation.
The problem is that there are negative values in income data.
I searched for log-transformation for negative values, and found this code.
Code:
sign(x) * log(1 + abs(x))
According to this post (http://blogs.sas.com/content/iml/201...f-pos-neg.html), this function acts like the log (base 10) function when x > 0.
However, when I calculate this function, the result was different from log (base 10) function.
For example, if x=1000, L(1000)=sign(1000)*log(1+abs(1000)) = 6.908 while log10(1000)=3.
Do I misunderstand something? Otherwise, is there other way to interpret this function?
Many thanks,
I'm implementing the analysis using the household's income data in 2010-2012.
Since the income data was not normally distributed (and have a wide range), I'd like to do the log-transformation.
The problem is that there are negative values in income data.
I searched for log-transformation for negative values, and found this code.
Code:
sign(x) * log(1 + abs(x))
According to this post (http://blogs.sas.com/content/iml/201...f-pos-neg.html), this function acts like the log (base 10) function when x > 0.
However, when I calculate this function, the result was different from log (base 10) function.
For example, if x=1000, L(1000)=sign(1000)*log(1+abs(1000)) = 6.908 while log10(1000)=3.
Do I misunderstand something? Otherwise, is there other way to interpret this function?
Many thanks,
Comment