Overall Statistics
Total Trades
89
Average Win
0.08%
Average Loss
-1.87%
Compounding Annual Return
3.953%
Drawdown
54.400%
Expectancy
-0.841
Net Profit
119.423%
Sharpe Ratio
0.277
Probabilistic Sharpe Ratio
0.015%
Loss Rate
85%
Win Rate
15%
Profit-Loss Ratio
0.04
Alpha
0.054
Beta
-0.096
Annual Standard Deviation
0.175
Annual Variance
0.031
Information Ratio
-0.022
Tracking Error
0.261
Treynor Ratio
-0.505
Total Fees
$320.25
from Alphas.ConstantAlphaModel import ConstantAlphaModel
from Execution.ImmediateExecutionModel import ImmediateExecutionModel
from Portfolio.EqualWeightingPortfolioConstructionModel import EqualWeightingPortfolioConstructionModel
from Risk.MaximumDrawdownPercentPerSecurity import MaximumDrawdownPercentPerSecurity

class MultidimensionalModulatedAntennaArray(QCAlgorithm):

    def Initialize(self):
        self.SetStartDate(2000, 1, 1)  # Set Start Date
        self.SetCash(100000)  # Set Strategy Cash
        
        symbols = [ Symbol.Create("SPY", SecurityType.Equity, Market.USA) ]
        self.SetUniverseSelection( ManualUniverseSelectionModel(symbols) )
        self.UniverseSettings.Resolution = Resolution.Daily
        
        # Emit a constant Price Insight of Up direction
        self.AddAlpha(ConstantAlphaModel(InsightType.Price, InsightDirection.Up,Time.Multiply(Extensions.ToTimeSpan(Resolution.Daily), 100)))

        self.SetExecution(ImmediateExecutionModel())

        self.SetPortfolioConstruction(EqualWeightingPortfolioConstructionModel())

        self.SetRiskManagement(MaximumDrawdownPercentPerSecurity(0.01))

        


    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
        '''

        # if not self.Portfolio.Invested:
        #    self.SetHoldings("SPY", 1)
        pass