Specifying join keys and their matching conditions

join_by(var1) is shorthand for join_by(var1 == var1).

join_by(var1, var2) is shorthand for join_by(var1 == var1, var2 == var2).

The expression form in join_by() defines:

  • each key’s name – these can differ between the x and y data frame
  • the matching condition that defines the match between x$key and y$key: equality (==) or inequality (<, <= etc, and helpers)