Class Bin
- Namespace
- LinqStatistics
- Assembly
- LinqStatistics.dll
A discrete count of items which fall into a given range
[ComVisible(false)]
public sealed class Bin : ItemCount<double>, IEquatable<ItemCount<double>>, IEquatable<Bin>
- Inheritance
-
Bin
- Implements
- Inherited Members
Constructors
Bin(double, double, double, int, bool)
ctor
public Bin(double v, double min, double max, int count, bool maxInclusive = false)
Parameters
v
doubleRepresentative value for the Bin
min
doubleThe minimum value of the Range
max
doubleThe maximum value of the range
count
intThe number of items in the Bin
maxInclusive
boolShould Max be included in the Range or excluded - default is excluded
Properties
MaxInclusive
Determines whether Max should be included or excluded in the range
public bool MaxInclusive { get; }
Property Value
- bool
- A discrete count of items which fall into a given range
Range
The range
public Range<double> Range { get; }
Property Value
Methods
Contains(double)
Determines if a value is contained with the segment
public bool Contains(double item)
Parameters
item
doubleThe item to check
Returns
- bool
True if item is contained in the range - taking into acount MaxInclusive
Equals(Bin)
public bool Equals(Bin other)
Parameters
other
Bin
Returns
Equals(object)
public override bool Equals(object obj)
Parameters
obj
object
Returns
GetHashCode()
public override int GetHashCode()
Returns
ToString()
public override string ToString()
Returns
Operators
operator ==(Bin, Bin)
public static bool operator ==(Bin lhs, Bin rhs)
Parameters
Returns
operator !=(Bin, Bin)
public static bool operator !=(Bin lhs, Bin rhs)