jsat.testing.goodnessoffit
Class KSTest
- java.lang.Object
-
- jsat.testing.goodnessoffit.KSTest
-
public class KSTest extends java.lang.Object
-
-
Constructor Summary
Constructors Constructor and Description KSTest(Vec v)Creates a new statistical test for testing.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method and Description voidsetBaseData(Vec v)Change the original sample to vdoubletestData(Vec data)Returns the p-value for the 2 sample KS Test against the given data set data.doubletestDist(ContinuousDistribution cd)Returns the p-value for the KS Test against the given distribution cd.
-
-
-
Constructor Detail
-
KSTest
public KSTest(Vec v)
Creates a new statistical test for testing. The 1 sample test, with v being the 1 sample. The 1 sample test compare the data to a given distribution, and see if it does not belong to the given distribution. The 2 sample test is designed to tell if the data is not from the same population.- Parameters:
v- the date to be one of the samples
-
-
Method Detail
-
setBaseData
public void setBaseData(Vec v)
Change the original sample to v- Parameters:
v- the new original sample.
-
testDist
public double testDist(ContinuousDistribution cd)
Returns the p-value for the KS Test against the given distribution cd.
The null hypothesis of this test is that the given data set belongs to the given distribution.
The alternative hypothesis is that the data set does not belong to the given distribution.- Parameters:
cd- the distribution to compare against- Returns:
- the p-value of the test against this distribution
-
testData
public double testData(Vec data)
Returns the p-value for the 2 sample KS Test against the given data set data.
The null hypothesis of this test is that the given data set is from the same population as data
The alternative hypothesis is that the data set does not belong to the same population as data- Parameters:
data- the other distribution to compare against- Returns:
- the p-value of the test against this data set
-
-
DataMelt 3.0 © DataMelt by jWork.ORG