Become an expert in R — Interactive courses, Cheat Sheets, certificates and more!
Get Started for Free

elements

Elements of the TidySet


Description

Given TidySet retrieve the elements or substitute them.

Usage

elements(object)

elements(object) <- value

## S4 method for signature 'TidySet'
elements(object)

## S4 replacement method for signature 'TidySet'
elements(object) <- value

replace_elements(object, value)

## S4 method for signature 'TidySet'
nElements(object)

Arguments

object

A TidySet object.

value

Modification of the elements.

Value

A data.frame with information about the elements

Methods (by class)

  • TidySet: Retrieve the elements

  • TidySet: Modify the elements

  • TidySet: Return the number of elements

See Also

Other slots: relations(), sets()

Examples

TS <- tidySet(list(A = letters[1:5], B = letters[2:10]))
elements(TS)
elements(TS) <- data.frame(elements = letters[10:1])
TS2 <- replace_elements(TS, data.frame(elements = letters[1:11]))
nElements(TS)
nElements(TS2)

BaseSet

Working with Sets the Tidy Way

v0.0.16
MIT + file LICENSE
Authors
Lluís Revilla Sancho [aut, cre] (<https://orcid.org/0000-0001-9747-2570>), Zebulun Arendsee [rev], Jennifer Chang [rev]
Initial release

We don't support your browser anymore

Please choose more modern alternatives, such as Google Chrome or Mozilla Firefox.