Back to Aurora Vision Library website

You are here: Start » Function Reference » Basic » Statistics » NthValue

NthValue


Header: STD.h
Namespace: avl
Module: FoundationLite

Computes n-th smallest value in an array (0-indexed). The array must be not empty.

Syntax

void avl::NthValue
(
	const atl::Array<float>& inValues,
	int inN,
	float& outNthValue
)

Parameters

Name Type Default Description
Input value inValues const Array<float>&
Input value inN int
Output value outNthValue float&

Hints

  • If the input array is not guaranteed to be non-empty, precede this filter with SkipEmptyArray.

Errors

List of possible exceptions:

Error type Description
DomainError Selected N exceed the array index range in NthValue.