append {base}R Documentation

Vector Merging

Description

Add elements to a vector.

Usage

append(x, values, after = length(x))

Arguments

x

the vector the values are to be appended to.

values

to be included in the modified vector.

after

a subscript, after which the values are to be appended.

Value

A vector containing the values in x with the elements of values appended after the specified element of x.

References

Becker RA, Chambers JM, Wilks AR (1988). The New S Language. Chapman and Hall/CRC, London.

Examples

append(1:5, 0:1, after = 3)

[Package base version 4.6.0 Index]