I'm not sure; but now it has improve a lot!
Thanks for all your help; the indicator is almost perfect! there is something wrong with the "cancelled divergences" but it does not have major importance; one thing I would like to add: the "Look back this many bars for divergences", but that does not so important either. Thanks for all your work for the community