View source: R/30-api-flexseq-core.R
| flexseq | R Documentation |
flexseq(...) creates an immutable sequence from ..., preserving element
order and optional names, with efficient persistent updates.
flexseq(...)
... |
Sequence elements. |
It is list-like in payload flexibility (any R object per element), but
sequence-oriented in API (push_*, peek_*, pop_*, indexing, split/concat).
flexseq is the base general-purpose structure in this package.
Specialized structures such as priority_queue, ordered_sequence, and
interval_index build on related internals but expose narrower semantics.
flexseq operations are persistent: updates return new objects and do not
mutate prior versions.
A flexseq object.
as_flexseq(), priority_queue(), ordered_sequence(), interval_index()
x <- flexseq(1, 2, 3)
x
y <- push_front(x, 0)
y
x # unchanged
named <- flexseq(a = 1, b = 2)
named
named[["a"]]
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.