Computes the Pearson correlation of two data sets, excluding pairs where either
value is missing.
Namespace:
CenterSpace.NMath.StatsAssembly: NMathStats (in NMathStats.dll) Version: 3.4.0.0
Syntax
| C# |
|---|
public static double NaNCorrelation( DoubleVector data1, DoubleVector data2 ) |
| Visual Basic (Declaration) |
|---|
Public Shared Function NaNCorrelation ( _ data1 As DoubleVector, _ data2 As DoubleVector _ ) As Double |
| Visual C++ |
|---|
public: static double NaNCorrelation( DoubleVector^ data1, DoubleVector^ data2 ) |
Parameters
- data1
- Type: CenterSpace.NMath.Core..::.DoubleVector
The first data set.
- data2
- Type: CenterSpace.NMath.Core..::.DoubleVector
The second set set.
Return Value
Correlation.
Exceptions
| Exception | Condition |
|---|---|
| CenterSpace.NMath.Core..::.InvalidArgumentException | Thrown if the given data has zero or one non-NaN pairs. |