An estimator of the mutual information based on a criterion for independence