Overall Statistics
Total Trades
1
Average Win
0%
Average Loss
0%
Compounding Annual Return
16.658%
Drawdown
34.100%
Expectancy
0
Net Profit
16.642%
Sharpe Ratio
0.7
Probabilistic Sharpe Ratio
35.764%
Loss Rate
0%
Win Rate
0%
Profit-Loss Ratio
0
Alpha
0
Beta
0.997
Annual Standard Deviation
0.337
Annual Variance
0.114
Information Ratio
-0.852
Tracking Error
0.001
Treynor Ratio
0.237
Total Fees
$15.01
Estimated Strategy Capacity
$15000000.00
class SPY_Buy_And_Hold_Benchmark(QCAlgorithm):

    def Initialize(self):
        self.SetCash(1000000) #Starting Cash
        self.SetStartDate(2020,2,7)
        self.SetEndDate(2021,2,7)
        
        self.spy = self.AddEquity("SPY", Resolution.Hour)
        #self.spy.SetDataNormalizationMode(DataNormalizationMode.Adjusted)
        
        self.SetBenchmark("SPY")
        
        #self.Schedule.On(self.DateRules.EveryDay("SPY"),self.TimeRules.AfterMarketOpen("SPY"),self.PlotStuff)
        #self.Schedule.On(self.DateRules.MonthStart("SPY"),self.TimeRules.AfterMarketOpen("SPY"),self.PlotStuff)

    def OnData(self, data):
        #3. Place an order for 100 shares of IWM and print the average fill price
        #4. Debug the AveragePrice of IWM
        if not self.Portfolio.Invested:
            self.SetHoldings("SPY",1)
    
    #def PlotStuff(self):
        #self.SetHoldings("SPY",1)