Description Usage Arguments Details Value
Vectors are sequence containers representing arrays that can change in size.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 | ## S3 method for class 'Vector'
as.list(vec)
vector_create(n = 0L)
vector_empty(vec)
vector_size(vec)
vector_front(vec)
vector_back(vec)
vector_push_back(vec, obj)
vector_pop_back(vec)
vector_at(vec, i)
vector_set_at(vec, i, obj)
## S3 method for class 'Vector'
print(vec, ...)
## S3 method for class 'Vector'
format(vec, ...)
## S3 method for class 'Vector'
vec[i]
## S3 replacement method for class 'Vector'
vec[i] <- value
vector_at(vec, i) <- value
|
vec |
a vector object |
n |
vector size |
obj |
an R object |
i |
position in the vector |
... |
other arguments passed to or from other methods |
value |
object to set |
as.list.Vector
converts a given vector object to an R list.
vector_create
creates a new vector.
vector_empty
determines if a given stack is empty or not.
vector_size
returns a size of vector.
vector_front
returns the first object of a given vector.
vector_back
returns the last object of a given vector.
vector_push_back
pushes a given object at the end of the vector.
vector_pop_back
removes the last element in the vector, effectively
reducing the container size by one.
vector_at
returns an object at position i in the vector.
vector_set_at
sets an object obj at position i in the vector.
print.Vector
prints the contents of the vector
(coerced to a list object) on the console.
format.Vector
pretty-prints the contents of the vector
(coerced to a list object) on the console.
[.Vector
returns an object at position i in the vector.
[<-.Vector
sets an object value at position i in the vector.
vector_at<-
sets an object value at position i in the vector.
as.list.Vector
returns an R list object.
vector_create
returns a new, empty vector.
vector_empty
returns a single logical value.
vector_size
returns a single integer value.
vector_front
returns a single RObject value or
throws an error if a vector is empty.
vector_back
returns a single RObject value or
throws an error if a vector is empty.
vector_push_back
does not return anything interesting.
vector_pop_back
does not return anything interesting. Throws an
error if a vector is empty.
vector_at
returns a single RObject value.
vector_set_at
does not return anything interesting.
print.Vector
returns the vector coerced to a list, invisibly.
format.Vector
returns the character representation
of the objects in the vector.
[.Vector
returns a single R object.
[<-.Vector
returns a modified vector
vector_at<-
returns a modified vector
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.