title: Plotting OHLC charts in python with matplotlib
body: <p>I have a list of candlestick objects, each one has 6 values (open, high, low, close, volume, timestamp). I want to use matplotlib.finance.candlestick2_ohlc(ax, opens, highs, lows, closes, width=4, colorup='k', colordown='r', alpha=0.75) function to plot this data. The thing is, how can i subdivide my list into opens, highs, lows and closes in order to load it to this function? </p>
  
  <p>Here's my candlestick class: </p>
  
  <pre><code>class Candle:
  #Candlestick chart object
  def __init__(self, open, high, low, close, volume, timeStamp):
      self.open = open
      self.high = high
      self.low = low
      self.close = close
      self.volume = volume
      self.timestamp = timeStamp
  
  def __str__(self):
      return """
      Open: %s
      High: %s
      Low: %s
      Close: %s
      Volume : %s
      Timestamp: %s""" %(self.open, self.high, self.low, self.close, self.volume, self.timestamp)
  </code></pre>
  
  <p>And this is my list construction methods: </p>
  
  <pre><code>def getTradeHistory(self, timeFrame, symbol, count):
      #Get the trade history from the API
  
      return self.client.Trade.Trade_getBucketed(binSize=timeFrame, partial=True, symbol=symbol, reverse=False, count=count).result()
  
  def constructCandles(self, th):
      #Iterate through list of trade history items and store them as candles in a list
  
      for candle in th :
          self.candles.append(Candle(candle['open'], candle['high'], candle['low'], candle['close'], candle['volume'], candle['timestamp']))
  </code></pre>