Skip to contents

Remove specified items from preferences.

Usage

pref_omit(x, items)

Arguments

x

A vector of preferences.

items

The names of the items which should be removed from the preferences in x.

Value

A new vector of preferences, but with items removed from each selection.

Examples

# Remove 'b'
pref_omit(preferences(c("a > b > c", "b > c > a")), "b")
#> [1] [a > c] [c > a]
# Remove 'b' and 'd'
pref_omit(preferences(c("a > b > c > d", "b > c > a > d")), c("b", "d"))
#> [1] [a > c] [c > a]