def testADOSC(self): barDs = self.__loadBarDS() self.assertTrue( compare(indicator.ADOSC(barDs, 252, 3, 10)[9], 841238.33)) # Original value was 841238.32 self.assertTrue( compare(indicator.ADOSC(barDs, 252, 3, 10)[9 + 1], 2255663.07)) self.assertTrue( compare(indicator.ADOSC(barDs, 252, 3, 10)[-2], -526700.32)) self.assertTrue( compare(indicator.ADOSC(barDs, 252, 3, 10)[-1], -1139932.729))
def testADOSC(self): barDs = self.__loadBarDS() self.assertAmountsAreEqual( indicator.ADOSC(barDs, 252, 3, 10)[9], 841238.33) # Original value was 841238.32 self.assertAmountsAreEqual( indicator.ADOSC(barDs, 252, 3, 10)[9 + 1], 2255663.07) self.assertAmountsAreEqual( indicator.ADOSC(barDs, 252, 3, 10)[-2], -526700.32) self.assertAmountsAreEqual( indicator.ADOSC(barDs, 252, 3, 10)[-1], -1139932.729)