Overall Statistics |
Total Trades 1 Average Win 0% Average Loss 0% Compounding Annual Return 34.022% Drawdown 5.400% Expectancy 0 Net Profit 15.687% Sharpe Ratio 2.866 Probabilistic Sharpe Ratio 84.227% Loss Rate 0% Win Rate 0% Profit-Loss Ratio 0 Alpha -0 Beta 0.995 Annual Standard Deviation 0.124 Annual Variance 0.015 Information Ratio -3.356 Tracking Error 0.001 Treynor Ratio 0.357 Total Fees $1.31 Estimated Strategy Capacity $71000000.00 Lowest Capacity Asset SPY R735QTJ8XC9X |
class SleepyMagentaPelican(QCAlgorithm): def Initialize(self): self.SetStartDate(2021, 2, 3) self.SetCash(100000) self.AddEquity("SPY", Resolution.Minute) def OnData(self, data): ''' OnData event is the primary entry point for your algorithm. Each new data point will be pumped in here. Arguments: data: Slice object keyed by symbol containing the stock data ''' # Check if we're not invested and then put portfolio 100% in the SPY ETF. if not self.Portfolio.Invested: insight = Insight.Price("SPY", timedelta(minutes = 20), InsightDirection.Up, 0.0025, 1.00, "MyAlphaModel", 1) self.SetHoldings("SPY", 1)