The documented function self.Plot able to plot only candle charts.

Here example:

class CalmOrangeGaur(QCAlgorithm):
    def Initialize(self):
........
        spy = self.AddEquity(self.sym, Resolution.Hour) #(!)
        ..........
        stockPlot = Chart('Trade Plot')
        from System.Drawing import Color
        stockPlot.AddSeries(Series('Price', SeriesType.Candle, '$', Color.Green)) #(!)
        self.AddChart(stockPlot)

def OnData(self, data):

..........
self.Plot('Trade Plot', 'Price', data.Bars["SPY"].Close)

the output is the DAILY candlesticks, but if we change SeriesType to Line,
we definitely get the hourly line chart, the same for minutes.

Question 1: How to get Hour/Minutes candles?

Question 2: Is it correct when we use argument data.Bar[xxx].Close and we get back, as a result, a candle series instead line?

Question 3: How to add a subChart to the existing candle chart (Vol for example)?

Question 4: Is it possible to draw just a vertical line or other figures like a semitransparent square?

 

Author