Overall Statistics |
Total Trades 3 Average Win 0% Average Loss -20.69% Compounding Annual Return -23.320% Drawdown 21.000% Expectancy -1 Net Profit -20.691% Sharpe Ratio -1.39 Probabilistic Sharpe Ratio 0.389% Loss Rate 100% Win Rate 0% Profit-Loss Ratio 0 Alpha -0.29 Beta 0.32 Annual Standard Deviation 0.161 Annual Variance 0.026 Information Ratio -1.617 Tracking Error 0.267 Treynor Ratio -0.697 Total Fees $3.00 |
class VentralNadionThrustAssembly(QCAlgorithm): def Initialize(self): self.SetStartDate(2020, 2, 15) # Set Start Date self.SetCash(100000) # Set Strategy Cash self.spy = self.AddEquity("SPY", Resolution.Hour).Symbol self.ordered = 0 def OnData(self, data): if not (data.ContainsKey(self.spy) and data[self.spy] is not None): return if self.ordered < 2: self.ordered += 1 self.MarketOrder(self.spy, 100) if self.ordered == 2: self.ordered += 1 self.StopMarketOrder(self.spy, -self.Portfolio[self.spy].Quantity, data[self.spy].Close * 0.7)