Closed wpzdm closed 5 years ago
And it is similar for integral_approx_estimator
.
Hi Abel, This sign is a choice made by design of the package. All pairwise algorithms output a float value between -1 and 1. 1 indicates the causal direction (1st variable causes the 2nd) whereas -1 indicates anticausal direction. The float value is often used to specify the confidence of the algorithm in its prediction.
I do understand your confusion however. I should add a warning/note in the docs.
Thanks for the feedback ! Best, Diviyan
Hi Diviyan,
Thanks for the reply!
Maybe I did not make myself clear enough. I was aware of sign of return value of pairwise algorithms in this package from your documentation. Actually, I meant that the return value of IGCI method contradicts the above. That is, given the current implementation, positive return value means anticausal direction (2nd variable causes the 1st).
Best, Abel
Whoops, you're right, I'll fix that asap
It should be done, I'll be closing this issue. Don't hesitate to reopen it if the issue remains. Thanks again for the feedback !
Hi Diviyan,
I think the sign of the IGCI score is wrong.
In the UAI 2010 paper, on page 5, at the beginning of sec 3.5, Cx2y = S(Py) - S(Px) after preprocessing. And on page 3, after Postulate 2, the paper says negative value of Cx2y indicates X cause Y.
Thus, in method
predict_proba
of classIGCI
, line 105, the entropy estimator should beeval_entropy(x) - eval_entropy(y)
(replacex
andy
). Now, positve return value indicates X cause Y.Running the code on CEP dataset, the result also agrees with the above.
Best, Abel