Are there any rules to be able to build the comparison? For instance, if the first column always has a value as in this example, then it's just a simple comparison of each value to the previous. We would need to know more about the data to build a usable calculation.
Please consider sharing a packaged workbook. Packaged workbooks and flows (and Tableau Public links): when, why, how