| NMathFunctionsFishersExactTest(Int32, Int32, Int32, Int32) Method |
Returns the one-tailed Fisher's Exact Test p-value for the specified 2 x 2 contingency table.
Namespace: CenterSpace.NMath.CoreAssembly: NMath (in NMath.dll) Version: 7.4
Syntax public static double FishersExactTest(
int a,
int b,
int c,
int d
)
Public Shared Function FishersExactTest (
a As Integer,
b As Integer,
c As Integer,
d As Integer
) As Double
public:
static double FishersExactTest(
int a,
int b,
int c,
int d
)
static member FishersExactTest :
a : int *
b : int *
c : int *
d : int -> float
Parameters
- a Int32
- Upper left cell in contingency table.
- b Int32
- Upper right cell in contingency table.
- c Int32
- Lower left cell in contingency table.
- d Int32
- Lower right cell in contingency table.
Return Value
DoubleThe lesser of the right and left tail p-value.
Exceptions Remarks
a, b, c and d are cell values for contingency table:
a b
c d
Fisher's exact test is so-called because the significance of the deviation from a null hypothesis can be calculated exactly,
rather than relying on an approximation.
Fisher's exact test is a useful alternative to the chi-square test in cases where sample sizes are small.
The usual rule of thumb for deciding whether the chi-squared approximation is good enough is whether the expected
values in all cells of the contingency table is greater than or equal to 5.
See Also