left_join question

# Combine the star_destroyer and millennium_falcon tables
millennium_falcon %>%
  left_join(star_destroyer, by=c("part_num","color_id"), suffix=c("_falcon","_star_destroyer"))

My question is by=c("part_num","color_id"). How to interpret 2 bys here? Does this mean we connect observations from 2 tables that share both the same part_num and the same color_id?

Yes, the data sets being joined must match in both of the columns.

1 Like

This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.