interweave {arrayMagic} | R Documentation

## interweave

### Description

The first object is "interweaved" with the second object and the resulting object with the following object and continued as long as the last object is reached. Note: `AsIs` class objects are coerced to a vector before interweaving starts.

### Usage

    interweave(...)

### Arguments

`...` | vectors, matrices, one- and two-dimensional arrays; an `AsIs` class object is coerced to a vector.

### Value

An "interweaved" object, cf. example.

### Author(s)

Andreas Buness <a.buness@dkfz.de>

### Examples

        x <- seq(1,100,2)
        y <- seq(2,100,2)
        z <- interweave(x,y)
        stopifnot( all.equal(z,1:100) )

[Package arrayMagic version 1.5.0 Index]