Skip to contents

Given a TidySet remove elements and the related relations and if required also the sets.

Usage

remove_element(object, elements, ...)

# S4 method for class 'TidySet,characterORfactor'
remove_element(object, elements)

Arguments

object

A TidySet object.

elements

The elements to be removed.

...

Placeholder for other arguments that could be passed to the method. Currently not used.

Value

A TidySet object.

Methods (by class)

  • remove_element(object = TidySet, elements = characterORfactor): Removes everything related to an element

Examples

relations <- data.frame(
    sets = c(rep("A", 5), "B"),
    elements = letters[seq_len(6)],
    fuzzy = runif(6)
)
TS <- tidySet(relations)
remove_element(TS, "c")
#>   elements sets     fuzzy
#> 1        a    A 0.2449280
#> 2        b    A 0.7811226
#> 3        d    A 0.8753579
#> 4        e    A 0.2957501
#> 5        f    B 0.9835254