Back to Adaptive Vision Library website

You are here: Start » Function Reference » Array Statistics » GetMedianElement

GetMedianElement


This is Filter Equivalent. This function may be present in generated code, but should not be used in hand-written code.

Gets array element corresponding to median value from the inValues array.

Syntax

void avl::GetMedianElement
(
	const atl::Array<Type>& inArray,
	const atl::Array<float>& inValues,
	Type& outElement,
	float& outValue,
	int& outIndex
)

Parameters

Name Type Default Description
inArray const Array<Type>& Elements from which element corresponding to median value will be chosen
inValues const Array<float>& Values defining the order
outElement Type& Element from the array
outValue float& Median value
outIndex int& Index of the median value

Errors

Error type Description
DomainError Inconsistent array sizes in GetMedianElement.
DomainError Empty input array in GetMedianElement.