Example #1
0
 def testLookupLargeTValue(self):
     """Tests a lookup when the given t-value is very large."""
     self.assertEqual(0.01, ttest._LookupPValue(500.0, 1))
     self.assertEqual(0.01, ttest._LookupPValue(-500.0, 1))
Example #2
0
 def testLookupExactMatch(self):
     """Tests a lookup when there is an exact match."""
     self.assertEqual(0.1, ttest._LookupPValue(3.182, 3))
     self.assertEqual(0.1, ttest._LookupPValue(-3.182, 3))
Example #3
0
 def testLookupAbove(self):
     """Tests a lookup when the given value is above an entry in the table."""
     self.assertEqual(0.2, ttest._LookupPValue(3.1, 2))
     self.assertEqual(0.2, ttest._LookupPValue(-3.1, 2))
Example #4
0
 def testLookupZeroTValue(self):
     """Tests a lookup when the given t-value is zero."""
     self.assertEqual(1, ttest._LookupPValue(0.0, 1))
     self.assertEqual(1, ttest._LookupPValue(0.0, 2))
Example #5
0
 def testLookupLargeDF(self):
     """Tests a lookup when the given degrees of freedom is large."""
     self.assertEqual(0.02, ttest._LookupPValue(5.0, 50))
Example #6
0
 def testLookupLargeDF(self):
   """Tests a lookup when the given degrees of freedom is large."""
   self.assertEqual(0.02, ttest._LookupPValue(5.0, 50))
Example #7
0
 def testLookupZeroTValue(self):
   """Tests a lookup when the given t-value is zero."""
   self.assertEqual(1, ttest._LookupPValue(0.0, 1))
   self.assertEqual(1, ttest._LookupPValue(0.0, 2))
Example #8
0
 def testLookupLargeTValue(self):
   """Tests a lookup when the given t-value is very large."""
   self.assertEqual(0.01, ttest._LookupPValue(500.0, 1))
   self.assertEqual(0.01, ttest._LookupPValue(-500.0, 1))
Example #9
0
 def testLookupAbove(self):
   """Tests a lookup when the given value is above an entry in the table."""
   self.assertEqual(0.2, ttest._LookupPValue(3.1, 2))
   self.assertEqual(0.2, ttest._LookupPValue(-3.1, 2))
Example #10
0
 def testLookupExactMatch(self):
   """Tests a lookup when there is an exact match."""
   self.assertEqual(0.1, ttest._LookupPValue(3.182, 3))
   self.assertEqual(0.1, ttest._LookupPValue(-3.182, 3))