Learn R Programming

tensorr (version 0.1.1)

matches: Match index in sparse tensor

Description

Matches a given index to the index of a non-zero value in a sparse tensor. Returns the index if there is match. Returns 0 if there is no match. Returns NA if the index is out of bounds.

Usage

matches(idx, x)

Arguments

idx

index

x

sptensor