Back

Question about the universe

Hi all, I want to add daily high, low and other self created paramenters to the universe. Can I just add these parameters to the CoarseFundamental universe or I have to create a new universe?

 class CoarseFundamental {
public long Volume; // Traded shares
public decimal DollarVolume; // Traded shares x Price
public decimal Price; // Yesterday close price
public Symbol Symbol; // Asset symbol
public bool HasFundamentalData; // Whether it has fundamental
}
 
 
Update Backtest








hmm you would need to subscribe to many stocks and filter them later after putting the data into a symbolclass.

so selecting s&p500:

https://github.com/QuantConnect/Lean/blob/master/Algorithm.Python/ConstituentsQC500GeneratorAlgorithm.py

other universe examples if you need some

https://github.com/QuantConnect/Lean/blob/c620e6036633942ff39fd600b8708ae74de16a84/Algorithm.Python/ETFGlobalRotationAlgorithm.pyhttps://www.quantconnect.com/forum/discussion/3432/momentum-based-asset-allocationhttps://www.quantconnect.com/forum/discussion/3327/enhanced-short-term-mean-reversion-algorithmhttps://www.quantconnect.com/forum/discussion/3214/piotroski-f-score-fundamental-filter--value-screen
1

Thanks, Michael. 

I am not sure if the current Python documentation is not completed or I missed something.

Can I know where to find the indicators library like the below example?

x.(???)

 filtered_fine = [x for x in fine if (x.CompanyReference.CountryId == "USA") and (x.CompanyReference.PrimaryExchangeID == "NYS" or x.CompanyReference.PrimaryExchangeID == "NAS") and ((self.Time - x.SecurityReference.IPODate).days > 180) and x.EarningReports.BasicAverageShares.ThreeMonths * (x.EarningReports.BasicEPS.TwelveMonths*x.ValuationRatios.PERatio) > 5e8] 
0

thats a

https://www.datacamp.com/community/tutorials/python-list-comprehension

which uses

https://www.quantconnect.com/data#fundamentals/usa/morningstar
0

Update Backtest





0

The material on this website is provided for informational purposes only and does not constitute an offer to sell, a solicitation to buy, or a recommendation or endorsement for any security or strategy, nor does it constitute an offer to provide investment advisory services by QuantConnect. In addition, the material offers no opinion with respect to the suitability of any security or specific investment. QuantConnect makes no guarantees as to the accuracy or completeness of the views expressed in the website. The views are subject to change, and may have become unreliable for various reasons, including changes in market conditions or economic circumstances. All investments involve risk, including loss of principal. You should consult with an investment professional before making any investment decisions.


Loading...

This discussion is closed