Learn R Programming

vvsculptor (version 0.4.10)

strict_left_join: strict_left_join

Description

A wrapper around dplyr's left_join, with an error message if duplicate values are present in the matching fields in y. This will prevent duplicating rows. See dplyr::left_join .

Usage

strict_left_join(x, y, by = NULL, ...)

Value

merged data frame

Arguments

x

data frame x (left)

y

data frame y (right)

by

unquoted variable names to join.

...

Pass further arguments to dplyr::left_join

See Also

Examples

Run this code
  left_df <- data.frame(id = c(1, 2, 3), name = c("Alice", "Bob", "Charlie"))
  right_df <- data.frame(id = c(1, 2, 4), age = c(20, 25, 30))
  strict_left_join(left_df, right_df, by = "id")

Run the code above in your browser using DataLab