Pandas “Can only compare identically-labeled DataFrame objects” error
Here’s a small example to demonstrate this (which only applied to DataFrames, not Series, until Pandas 0.19 where it applies to both): One solution is to sort the index first (Note: some functions require sorted indexes): Note: == is also sensitive to the order of columns, so you may have to use sort_index(axis=1): Note: This can still raise (if the index/columns aren’t … Read more