Description
Computes a histogram of the values in an array. The number of bins, the starting value and the size of a bin are user-specified.
-
Return Type
-
A McObject object.
A McObject of type mcobjTypeINTEGER holding an array of length-N (lNofBins of bins) containing a histogram of the values of Operand.
-
Syntax
-
object.McVectorHistogram (Operand, lNofBins, varBinStartAndSize)
The McVectorHistogram Method syntax has these parts: |
| object | An expression evaluating to an object of type McOMGlobal. | | Operand | Required. A Variant value. Array of values to compute the histogram for.
| | lNofBins | Required. A Long value. Number of bins (N) to create for the histogram.
| | varBinStartAndSize | Required. A Variant value. Length-2 array of the same type of as Operand, giving the StartValue and BinSize values for the histogram. The StartValue is the smallest value to be counted in the zero'th (first) bin; values less than StartValue are not counted. BinSize sets the size of each bin; values greater than or equal to StartValue+N*BinSize fall beyond the (N-1)'th (last) bin and are not counted.
| Remarks
The index of the bin to be incremented for any Value is computed as: Index=CLng((Value-StartValue)/BinSize), where the cast to an integral index truncates rather than rounds the result of the division.
|