it is important to understand that the goal is to know if in the end you have more upward variations than downward variations. I invented this algorithm that summarizes 99% of trades