Drop: Drop specified dimension from an array

View source: R/GSEA-by-boot.R

DropR Documentation

Drop specified dimension from an array

Description

Like drop(x) but only dropping specified dimensions. There is no testing that the specified dimensions are actually singletons.

Usage

Drop(x, d)

Arguments

x

array of at least d dimensions

d

dimension(s) to drop

Value

array x

Examples

x = array(1:4, dim=c(1, 2, 1, 2))
dx = MAST:::Drop(x, 1)
stopifnot(all(dim(dx)==c(2,1,2)))


RGLab/MAST documentation built on Sept. 30, 2023, 1:08 p.m.