CHistogram:SetBinAuto


The SetBinAuto method configures the histogram binning strategy to compute the number of bins and bin width automatically. After calling this method, Mira sets the bin count to be the lesser of the square root of the number of sample points or 100. The minimum and maximum data values are used as the histogram limits. Using these values, the bin width is computed to fit the number of bins into the data range.

Syntax

CHistogram:SetBinAuto()

bullet.gif    This method has no arguments or return value.

Remarks

If you do not call one of the SetBin methods, Mira defaults to this binning option. Normally, this method produces a nice default histogram. However, if the number of points is relatively small and the data values all have integer values, the auto setting can cause aliasing, in which a cell boundary falls on a real number between integer values. Aliasing produces a comb-like appearance with alternating cells going higher and lower. If the data all have integer values and you suspect aliasing, try using the SetBinWidth method with an integer value for the bin width.

Related Topics

CHistogram Class, SetBinCount, SetBinWidth


Mira Pro x64 Script User's Guide, Copyright Ⓒ 2023 Mirametrics, Inc. All Rights Reserved.