This abstract class provides a set of useful default methods that makes it
considerably easier to get started with a new S3 vector class. See
vignette("s3-vector") to learn how to use it to create your own S3
new_vctr(.data, ..., class = character(), inherit_base_type = TRUE)
Foundation of class. Must be a vector
Name-value pairs defining attributes
Name of subclass.
Does this class extend the base type of
The vctr class provides methods for many base generics using a smaller set of generics defined by this package. Generally, you should think carefully before overriding any of the methods that vctrs implements for you as they've been carefully planned to be internally consistent.
value to same type as
x, then call
as.POSIXct() methods call
as.list() method calls
[[ repeatedly, and the
method uses a standard technique to wrap a vector in a data frame.
as.difftime() are not generic functions
in base R, but have been reimplemented as generics in the
vctrs extends these and calls
vec_cast(). To inherit this
behaviour in a package, import and re-export the generic of interest
Mathematical operations including the Summary group generics (
all()), the Math group generics (