The problem I am working on is to select rows in a table A (N rows in total, many columns) if the value is %in% table B (K rows in total, 1 column only). Here N ~ 1 bn >> K ~ 100k
I wonder if I should just select rows by:
sub_set = df_A[df_A$Key %in% df_B$Key,]
Or should I utilize some inner_join or merge function:
sub_set = df_A %>% inner_join(df_B, by="Key")
When N is very large?