NMath Reference Guide

## Two |

Class TwoSampleKSTest performs a two-sample Kolmogorov-Smirnov test to compare
the distributions of values in two data sets.

Inheritance Hierarchy

Syntax

The TwoSampleKSTest type exposes the following members.

Constructors

Name | Description | |
---|---|---|

TwoSampleKSTest | Default constructor. Constructs an empty TwoSampleKSTest instance. | |

TwoSampleKSTest(Double, Double) | Constructs a TwoSampleKSTest from the given samples. | |

TwoSampleKSTest(DoubleVector, DoubleVector) | Constructs a TwoSampleKSTest from the given samples. | |

TwoSampleKSTest(IDFColumn, IDFColumn) | Constructs a TwoSampleKSTest from the given samples. | |

TwoSampleKSTest(Int32, Int32) | Constructs a TwoSampleKSTest from the given samples. | |

TwoSampleKSTest(Double, Double, Double) | Constructs a TwoSampleKSTest from the given samples and specified alpha level. | |

TwoSampleKSTest(DoubleVector, DoubleVector, Double) | Constructs a TwoSampleKSTest from the given samples and specified alpha level. | |

TwoSampleKSTest(IDFColumn, IDFColumn, Double) | Constructs a TwoSampleKSTest from the given samples and specified alpha level. | |

TwoSampleKSTest(Int32, Int32, Double) | Constructs a TwoSampleKSTest from the given samples and specified alpha level. |

Properties

Name | Description | |
---|---|---|

Alpha | Gets and sets the alpha level associated with this hypothesis test. | |

CriticalValue | Gets the critical value based on the current alpha level associated with this hypothesis test. | |

DefaultAlpha | Gets and sets the default alpha level associated with TwoSampleKSTests. | |

N1 | Gets the size of the first sample. | |

N2 | Gets the size of the second sample. | |

P | Gets the p-value associated with the test statistic. | |

Reject | Tests whether the null hypothesis can be rejected, using the current alpha level. | |

Statistic | Gets the value of the test statistic associated with this hypothesis test. |

Methods

Name | Description | |
---|---|---|

Clone | Creates a deep copy of this TwoSampleKSTest. | |

Update(Double, Double) | Updates this test with new sample data. | |

Update(DoubleVector, DoubleVector) | Updates this test with new sample data. | |

Update(IDFColumn, IDFColumn) | Updates this test with new sample data. | |

Update(Int32, Int32) | Updates this test with new sample data. |

Remarks

For each potential value x, the Kolmogorov-Smirnov test compares the
proportion of values in the first sample less than x with the proportion
of values in the second sample less than x. The null hypothesis is that
the two samples have the same continuous distribution. The alternative
hypothesis is that they have different continuous distributions.

See Also