Ejemplo n.º 1
0
class YahooDAM(BaseDAM):
    ''' Yahoo DAM '''
    def __init__(self):
        ''' constructor '''
        super(YahooDAM, self).__init__()
        self.__yf = YahooFinance()

    def readQuotes(self, start, end):
        ''' read quotes from Yahoo Financial'''
        if self.symbol is None:
            LOG.debug('Symbol is None')
            return []

        return self.__yf.getQuotes(self.symbol, start, end)
Ejemplo n.º 2
0
class YahooDAM(BaseDAM):
    ''' Yahoo DAM '''

    def __init__(self):
        ''' constructor '''
        super(YahooDAM, self).__init__()
        self.__yf = YahooFinance()

    def readQuotes(self, start, end):
        ''' read quotes from Yahoo Financial'''
        if self.symbol is None:
            LOG.debug('Symbol is None')
            return []

        return self.__yf.getQuotes(self.symbol, start, end)
Ejemplo n.º 3
0
 def __init__(self):
     ''' constructor '''
     super(YahooDAM, self).__init__()
     self.__yf = YahooFinance()
Ejemplo n.º 4
0
 def testGetHistoricalPrices(self):
     yahooFinance = YahooFinance()
     data = yahooFinance.getQuotes('^STI', '20110101', '20110110')
     self.assertNotEqual(0, len(data))
Ejemplo n.º 5
0
 def testGetHistoricalPrices(self):
     yahooFinance = YahooFinance()
     data = yahooFinance.getQuotes('^STI', '20110101', '20110110')
     self.assertNotEqual(0, len(data))
Ejemplo n.º 6
0
 def __init__(self):
     ''' constructor '''
     super(YahooDAM, self).__init__()
     self.__yf = YahooFinance()