def testStockChartsSMA_BoundedSeq(self):
     # Test data from http://stockcharts.com/school/doku.php?id=chart_school:technical_indicators:moving_averages
     common.test_from_csv(self,
                          "sc-sma-10.csv",
                          lambda inputDS: ma.SMA(inputDS, 10),
                          maxLen=1)
     common.test_from_csv(self,
                          "sc-sma-10.csv",
                          lambda inputDS: ma.SMA(inputDS, 10),
                          maxLen=2)
     common.test_from_csv(self,
                          "sc-sma-10.csv",
                          lambda inputDS: ma.SMA(inputDS, 10),
                          maxLen=4)
     common.test_from_csv(self,
                          "sc-sma-10.csv",
                          lambda inputDS: ma.SMA(inputDS, 10),
                          maxLen=1000)
Esempio n. 2
0
 def testStockChartsRSI(self):
     # Test data from http://stockcharts.com/school/doku.php?id=chart_school:technical_indicators:relative_strength_in
     common.test_from_csv(self, "rsi-test.csv",
                          lambda inputDS: rsi.RSI(inputDS, 14), 3)
 def testStockChartsEMA(self):
     # Test data from http://stockcharts.com/school/doku.php?id=chart_school:technical_indicators:moving_averages
     common.test_from_csv(self, "sc-ema-10.csv",
                          lambda inputDS: ma.EMA(inputDS, 10), 3)
 def testNinjaTraderSMA(self):
     common.test_from_csv(self, "nt-sma-15.csv",
                          lambda inputDS: ma.SMA(inputDS, 15), 3)
	def testStockChartsRSI(self):
		# Test data from http://stockcharts.com/school/doku.php?id=chart_school:technical_indicators:relative_strength_in
		common.test_from_csv(self, "rsi-test.csv", lambda inputDS: rsi.RSI(inputDS, 14), 3)
	def testStockChartsRSI_Reverse(self):
		# Test in reverse order to trigger recursive calls.
		# Test data from http://stockcharts.com/school/doku.php?id=chart_school:technical_indicators:relative_strength_in
		common.test_from_csv(self, "rsi-test.csv", lambda inputDS: rsi.RSI(inputDS, 14), 3, True)
	def testNinjaTraderSMA(self):
		common.test_from_csv(self, "nt-sma-15.csv", lambda inputDS: ma.SMA(inputDS, 15), 3)
	def testStockChartsSMA(self):
		# Test data from http://stockcharts.com/school/doku.php?id=chart_school:technical_indicators:moving_averages
		common.test_from_csv(self, "sc-sma-10.csv", lambda inputDS: ma.SMA(inputDS, 10))
Esempio n. 9
0
	def testStockChartsEMA_Reverse(self):
		# Test in reverse order to trigger recursive calls.
		# Test data from http://stockcharts.com/school/doku.php?id=chart_school:technical_indicators:moving_averages
		common.test_from_csv(self, "sc-ema-10.csv", lambda inputDS: ma.EMA(inputDS, 10), 3, True)
Esempio n. 10
0
 def testStockChartsRSI_Reverse(self):
     # Test in reverse order to trigger recursive calls.
     # Test data from http://stockcharts.com/school/doku.php?id=chart_school:technical_indicators:relative_strength_in
     common.test_from_csv(self, "rsi-test.csv",
                          lambda inputDS: rsi.RSI(inputDS, 14), 3, True)
Esempio n. 11
0
 def testStockChartsEMA_Reverse(self):
     # Test in reverse order to trigger recursive calls.
     # Test data from http://stockcharts.com/school/doku.php?id=chart_school:technical_indicators:moving_averages
     common.test_from_csv(self, "sc-ema-10.csv",
                          lambda inputDS: ma.EMA(inputDS, 10), 3, True)