Histogram Class

Represents a histogram.

Definition

Namespace: Meta.Numerics.Statistics
Assembly: Meta.Numerics (in Meta.Numerics.dll) Version: 4.2.0+6d77d64445f7d5d91b12e331399c4362ecb25333
C#
public sealed class Histogram
Inheritance
Object    Histogram

Remarks

A histogram stores the number of occurrences of a value (called the count) within a set of ranges (called bins). It is the natural storage of discrete, univariate data. The natural system to store continuous univariate data is the ListT class, but often histograms are also used for continuous data, for example because there is too much data to record each value individually.

Constructors

Histogram(IListDouble) Create a histogram with the given bin borders.
Histogram(Int32) Creates a histogram with the given number of bins.

Properties

AboveRangeBin Gets a bin for all values above the histogram range.
BelowRangeBin Gets a bin for all values below the histogram range.
Bins Gets a collection of histogram bins.
Range The range of values in the histogram.
TotalCounts Gets the total number of counts in the histogram.

Methods

Add(Double) Adds a new value to the histogram.
Add(Double, Int32) Increments a histogram bin corredponding to value by the specified amount.
ChiSquaredTest Performs a χ2 test comparing the histogram to the given distribution.
Clear Sets all bin counts to zero.
EqualsDetermines whether the specified object is equal to the current object.
(Inherited from Object)
GetHashCodeServes as the default hash function.
(Inherited from Object)
GetTypeGets the Type of the current instance.
(Inherited from Object)
ToStringReturns a string that represents the current object.
(Inherited from Object)

See Also