Dear Statalists,

I am applying logs to two variables:

Code:
gen In_Arg_X_Bra=ln(Arg_X_Bra+1)
gen In_Chn_X_LAC=ln(Chn_X_LAC+1)
And then running:

Code:
pwcorr In_Arg_X_Bra In_Chn_X_LAC,sig
Before -In- the correlation of the same two variables is 0.03 and after -In- it is 0.36 (both significant p = 0.00). I need the two variables not to be correlated since I am running a -ivregress gmm- regression where Arg_X_Bra is the dependent variable while Chn_X_LAC is the instrumental variable (IV). This is true, but not when transforming to log, making my IV useless.

How is this possible? Could this be related to the fact that I am using ln(X+1) as a way of getting around the impossibility of calculating ln(X) when X = 0? I have many 0 values due to zero trade between countries. In that case, I welcome any suggestions.

Thanks a lot,
Giuliana.