Click or drag to resize
Accord.NET (logo)

VectorHistogram Method (Int32)

Counts how many times an integer label appears in a vector (i.e. creates an histogram of integer values assuming possible values start at zero and go up to the maximum value of in the vector).

Namespace:  Accord.Math
Assembly:  Accord.Math (in Accord.Math.dll) Version: 3.8.0
Syntax
public static int[] Histogram(
	this int[] labels
)
Request Example View Source

Parameters

labels
Type: SystemInt32
An array containing the integer labels to be counted.

Return Value

Type: Int32
An integer array of size corresponding to the maximum label in the vector labels, containing how many times each possible label appears in labels.

Usage Note

In Visual Basic and C#, you can call this method as an instance method on any object of type . When you use instance method syntax to call this method, omit the first parameter. For more information, see Extension Methods (Visual Basic) or Extension Methods (C# Programming Guide).
See Also