Interface IUnivariateDistribution<TObservation>
Common interface for univariate probability distributions.
Namespace: Mars.Numerics.Statistics.Base
Assembly: Mars.Numerics.dll
Syntax
public interface IUnivariateDistribution<TObservation>
Type Parameters
Name | Description |
---|---|
TObservation |
Remarks
This interface is implemented by both univariate UnivariateDiscreteDistribution and Continuous Distributions . However, unlike IUnivariateDistribution, this interface has a generic parameter that allows to define the type of the distribution values (i.e. double).
Properties
Entropy
Gets entropy of the distribution.
Declaration
double Entropy { get; }
Property Value
Type | Description |
---|---|
System.Double | The distribution's entropy. |
Mean
Gets the mean value for the distribution.
Declaration
double Mean { get; }
Property Value
Type | Description |
---|---|
System.Double | The distribution's mean. |
Median
Gets the median value for the distribution.
Declaration
double Median { get; }
Property Value
Type | Description |
---|---|
System.Double | The distribution's median. |
Mode
Gets the mode value for the distribution.
Declaration
double Mode { get; }
Property Value
Type | Description |
---|---|
System.Double | The distribution's mode. |
Support
Gets the support interval for this distribution.
Declaration
DoubleRange Support { get; }
Property Value
Type | Description |
---|---|
DoubleRange | A DoubleRange containing the support interval for this distribution. |
Variance
Gets the variance value for the distribution.
Declaration
double Variance { get; }
Property Value
Type | Description |
---|---|
System.Double | The distribution's variance. |
Methods
CumulativeHazardFunction(TObservation)
Gets the cumulative hazard function for this
distribution evaluated at point
x
.
Declaration
double CumulativeHazardFunction(TObservation x)
Parameters
Type | Name | Description |
---|---|---|
TObservation | x | A single point in the distribution range. |
Returns
Type | Description |
---|---|
System.Double |
The cumulative hazard function H(x)
evaluated at x in the current distribution.
|
HazardFunction(TObservation)
Gets the hazard function, also known as the failure rate or
the conditional failure density function for this distribution
evaluated at point
x
.
Declaration
double HazardFunction(TObservation x)
Parameters
Type | Name | Description |
---|---|---|
TObservation | x | A single point in the distribution range. |
Returns
Type | Description |
---|---|
System.Double |
The conditional failure density function h(x)
evaluated at x in the current distribution.
|
Remarks
The hazard function is the ratio of the probability
density function f(x) to the survival function, S(x).
InverseDistributionFunction(Double)
Gets the inverse of the cumulative distribution function (icdf) for
this distribution evaluated at probability
p
. This function
is also known as the Quantile function.
Declaration
TObservation InverseDistributionFunction(double p)
Parameters
Type | Name | Description |
---|---|---|
System.Double | p | A probability value between 0 and 1. |
Returns
Type | Description |
---|---|
TObservation | A sample which could original the given probability value when applied in the DistributionFunction(Double[]). |
Remarks
The Inverse Cumulative Distribution Function (ICDF) specifies, for
a given probability, the value which the random variable will be at,
or below, with that probability.