interweave: Interweave vectors

View source: R/skUtils.R

interweaveR Documentation

Interweave vectors

Description

Interweave vectors, such that the result features the first value from vector A, then the first value from vector B, then the second value from vector A, etc.

Usage

interweave(...)

Arguments

...

Any number of vectors of equal length or length 1.

Value

The input vectors interwoven into one.

Author(s)

Sercan Kahveci

Examples

# Interweave 3 equal-length vectors 
interweave(1:3, 4:6, 7:9)

# Interweave vector with single value
interweave(1:5, 0)


Spiritspeak/skMisc documentation built on April 12, 2025, 5:40 a.m.