Index<T>.Lookup Method

Definition

Namespace: Numerics.NET.DataAnalysis
Assembly: Numerics.NET (in Numerics.NET.dll) Version: 9.0.0

Overload List

Lookup(IEnumerable<T>) Maps a sequence of keys to their position in the index.
Lookup(T) Maps the specified key to its position in the index.

Lookup(IEnumerable<T>)

Maps a sequence of keys to their position in the index.
C#
public virtual int[] Lookup(
	IEnumerable<T> values
)

Parameters

values  IEnumerable<T>
A sequence of keys to locate in the index.

Return Value

Int32[]
An array containing the mapped position of the elements of values. If the key was found in the index, then the mapped position is the zero-based position of the first occurance of the value in the index; otherwise the mapped position is -1.

Lookup(T)

Maps the specified key to its position in the index.
C#
public int Lookup(
	T key
)

Parameters

key  T
The key to locate.

Return Value

Int32
If key was found in the index, the zero-based position of the key in the index; otherwise -1.

See Also