dfcompare¶
-
class
dfcompare.
Different
(l, r, diff)[source]¶ Indicate that two rows are different
Variables: - left – left row
- right – right row
- diff – indices of columns that are different, exclude the index (first) column
-
class
dfcompare.
Identical
(l, r)[source]¶ Indicate that two rows are identical
Variables: - left – left row
- right – right row
-
class
dfcompare.
Unmatched
(row, side)[source]¶ Indicate that this row is in one side only
Variables: - row – row content
- side – 0 means in left only, 1 means in right only
-
dfcompare.
compare
(left, right, iterator=False, sort=True)[source]¶ Compare 2 data sets
Parameters: - left (DataFrame or iterable of DataFrame) – data set to be compared on left side
- right (DataFrame or iterable of DataFrame) – data set to be compared on right side
- iterator (bool) – whether left and right are iterable or single DataFrames
- sort (bool) – whether sort the inputs before comparing
Returns: iterator of diff results, which consist of
Identical
,Different
, orUnmatched