Skip to content

max_diffs and row-wise compare for large data frames #110

Description

@krlmlr

max_diffs is ignored for rowwise compare of data frames (and the columnwise comparison is shown in addition):

library(waldo)

compare(data.frame(a = 1:20), data.frame(a = 20:1))
#> old vs new
#>              a
#> - old[1, ]   1
#> + new[1, ]  20
#> - old[2, ]   2
#> + new[2, ]  19
#> - old[3, ]   3
#> + new[3, ]  18
#> - old[4, ]   4
#> + new[4, ]  17
#> - old[5, ]   5
#> + new[5, ]  16
#> - old[6, ]   6
#> + new[6, ]  15
#> - old[7, ]   7
#> + new[7, ]  14
#> - old[8, ]   8
#> + new[8, ]  13
#> - old[9, ]   9
#> + new[9, ]  12
#> - old[10, ] 10
#> + new[10, ] 11
#> - old[11, ] 11
#> + new[11, ] 10
#> - old[12, ] 12
#> + new[12, ]  9
#> - old[13, ] 13
#> + new[13, ]  8
#> - old[14, ] 14
#> + new[14, ]  7
#> - old[15, ] 15
#> + new[15, ]  6
#> - old[16, ] 16
#> + new[16, ]  5
#> - old[17, ] 17
#> + new[17, ]  4
#> - old[18, ] 18
#> + new[18, ]  3
#> - old[19, ] 19
#> + new[19, ]  2
#> - old[20, ] 20
#> + new[20, ]  1
#> 
#> `old$a`:  1  2  3  4  5  6  7  8  9 10 and 10 more...
#> `new$a`: 20 19 18 17 16 15 14 13 12 11            ...

Created on 2021-09-25 by the reprex package (v2.0.1)

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions