Overall Statistics
Total Trades
0
Average Win
0%
Average Loss
0%
Compounding Annual Return
0%
Drawdown
0%
Expectancy
0
Net Profit
0%
Sharpe Ratio
0
Probabilistic Sharpe Ratio
0%
Loss Rate
0%
Win Rate
0%
Profit-Loss Ratio
0
Alpha
0
Beta
0
Annual Standard Deviation
0
Annual Variance
0
Information Ratio
0
Tracking Error
0
Treynor Ratio
0
Total Fees
$0.00
#https://www.quantconnect.com/docs/algorithm-reference/universes#Universes-Coarse-Universe-Selection
#https://www.quantconnect.com/forum/discussion/6485/onsecuritieschanged-questions/p1
#https://www.quantconnect.com/forum/discussion/9751/create-rating-based-on-coarse-and-fine-selection/p1
class UncoupledResistancePrism(QCAlgorithm):

    def Initialize(self):
        self.SetStartDate(2020, 12, 24)  # Set Start Date
        self.SetEndDate(2020, 12, 24)    # Set Start Date
        self.SetCash(100000)  # Set Strategy Cash
    
        self.AddUniverse(self.Coarse, self.Fine)
        
    def Coarse(self, coarse):
        symbols = ['MDLA', 'CRSP','GAN', 'GNSS','PEP','JNJ', 'OSS', 'ZDGE']
        return [Symbol.Create(symbol, SecurityType.Equity, Market.USA) for symbol in symbols]
    
    def Fine(self, fine):
        self.Log("symbol,type,grwgrade,grwscore,valscore,pe,eps,shs,rev,curatio,qratio,debteq,fcf,roe")
        for f in fine:
            
            self.Log(str(f.Symbol.Value)
            + "," + str(f.AssetClassification.StockType)
            + "," + str(f.AssetClassification.GrowthGrade)
            + "," + '{:3.1f}'.format(f.AssetClassification.GrowthScore)
            + "," + '{:3.1f}'.format(f.AssetClassification.ValueScore)
            + "," + '{:3.1f}'.format(f.ValuationRatios.PERatio)
            + "," + '{:3.2f}'.format(f.EarningReports.BasicEPS.TwelveMonths)
            + "," + '{:3.0f}'.format(f.EarningReports.BasicAverageShares.ThreeMonths / 1000000)
            + "," + '{:3.1f}'.format((f.OperationRatios.RevenueGrowth.Value) * 100)
            + "," + '{:3.1f}'.format(f.OperationRatios.QuickRatio.Value)
            + "," + '{:3.1f}'.format(f.OperationRatios.CurrentRatio.Value)
            + "," + '{:3.1f}'.format(f.OperationRatios.TotalDebtEquityRatio.Value)
            + "," + '{:3.1f}'.format(f.ValuationRatios.FCFYield * 100)
            + "," + '{:3.1f}'.format(f.OperationRatios.ROE.Value * 100))
            
        return []