Keywords - Function groups - @ A B C D E F G H I J K L M N O P Q R S T U V W X Y Z

Library: xplore
See also: | ~ reshape reduce

Quantlet: stack
Description: Joins two arrays along the third dimension.

Usage: z = stack (x, y)
Input:
x d1 x d2 x p array
y d1 x d2 x q array
Output:
z stack of x and y

Note:

Example:
library("xplore")
x = reshape(1:8, #(2,4))
y = matrix(2, 4)
stack(x, y)

Result:
Contents of z
[,,1,1,1,1,1,1]
[1,]     1     3     5     7
[2,]     2     4     6     8
[,,2,1,1,1,1,1]
[1,]     1     1     1     1
[2,]     1     1     1     1



Author: T. Koetter, 19960424 license MD*Tech
(C) MD*TECH Method and Data Technologies, 05.02.2006