subs2ind: Convert matrix subscripts to linear index

Description Usage Arguments Value

View source: R/utils.R

Description

Takes subscripts as list of lists or data frame and converts them to linear index.

Usage

1
subs2ind(subs, dims)

Arguments

subs

Subscripts as list of lists of data frame.

dims

An n-dimensional integer vector. Each element of this vector indicates the size of the corresponding dimension in the n-dimensional matrixc.

Value

In integer vector with linear indexes.


noah documentation built on Jan. 18, 2021, 5:06 p.m.