rep2abI: Replicate Vectors into 'abIndex' Result

Description Usage Arguments Value See Also Examples

View source: R/abIndex.R

Description

rep2abI(x, times) conceptually computes rep.int(x, times) but with an abIndex class result.

Usage

1
rep2abI(x, times)

Arguments

x

numeric vector

times

integer (valued) scalar: the number of repetitions

Value

a vector of class abIndex

See Also

rep.int(), the base function; abIseq, abIndex.

Examples

1
2
3
(ab <- rep2abI(2:7, 4))
stopifnot(identical(as(ab, "numeric"),
	   rep(2:7, 4)))

Matrix documentation built on Oct. 30, 2019, 4:56 p.m.