Learn R Programming

easyr (version 0.3-1)

drows: Get Rows with Duplicates

Description

Pulls all rows with duplicates in a column, not just the duplicate row. Author: Bryce Chamberlain.

Usage

drows(x, c, na = FALSE)

Arguments

x

Data frame.

c

Column as vector or string.

na

Consider multiple NAs as duplicates?

Value

Rows from the data frame in which the column is duplicated.

Examples

Run this code
# NOT RUN {
ddt = dplyr::bind_rows( cars, utils::head( cars, 10 ) )
drows( ddt, 'speed' )
# }

Run the code above in your browser using DataLab