Learn R Programming

wrangle (version 0.6.4)

unsorted.data.frame: Extract records whose relative positions would change if sorted.

Description

Extracts records whose relative positions would change if sorted, i.e. records that would not have the same nearest neighbors (before and after). misplaced() returns the index that extracts these records.

Usage

# S3 method for data.frame
unsorted(x, ...)

Value

data.frame, possibly grouped_df

Arguments

x

data.frame

...

optional grouping columns (named arguments are ignored)

See Also

na dup

Other unsorted: misplaced.data.frame(), misplaced(), unsorted()