Constructs a NormalDistribution instance with the given mean and variance.
Namespace:
CenterSpace.NMath.StatsAssembly: NMathStats (in NMathStats.dll) Version: 3.4.0.0
Syntax
| C# |
|---|
public NormalDistribution( double mean, double var ) |
| Visual Basic (Declaration) |
|---|
Public Sub New ( _ mean As Double, _ var As Double _ ) |
| Visual C++ |
|---|
public: NormalDistribution( double mean, double var ) |
Parameters
- mean
- Type: System..::.Double
The mean of the density.
- var
- Type: System..::.Double
The variance of the density. Must be positive.
Remarks
The variance of the distribution is the standard deviation squared.
Exceptions
| Exception | Condition |
|---|---|
| CenterSpace.NMath.Core..::.InvalidArgumentException | Thrown if the variance is less than or equal to zero. |