About US Equity Security Master

The US Equity Security Master dataset by QuantConnect tracks US Equity corporate actions. The data covers approximately 27,500 US Equities, starts in January 1998, and is delivered on a daily update frequency. With the map and factor files installed in LEAN, all corporate actions are automatically handled and passed into your algorithm as events.


About QuantConnect

QuantConnect was founded in 2012 to serve quants everywhere with the best possible algorithmic trading technology. Seeking to disrupt a notoriously closed-source industry, QuantConnect takes a radically open-source approach to algorithmic trading. Through the QuantConnect web platform, more than 50,000 quants are served every month.

Add US Equity Security Master

Add Dataset Create Free QuantConnect Account

About QuantConnect

QuantConnect was founded in 2012 to serve quants everywhere with the best possible algorithmic trading technology. Seeking to disrupt a notoriously closed-source industry, QuantConnect takes a radically open-source approach to algorithmic trading. Through the QuantConnect web platform, more than 50,000 quants are served every month.


Algorithm Example

class USEquitySecurityMasterAlgorithm (QCAlgorithm):

    def Initialize(self):
        self.SetStartDate(1998, 1, 1)
        self.SetCash(1000000)
        
        self.equity = self.AddEquity("AAPL", Resolution.Daily).Symbol
        
    def OnData(self, slice: Slice) -> None:
        # Accessing Data - Splits
        split = slice.Splits.get(self.equity)
        if split:
            self.Debug(f"{self.Time} >> SPLIT >> {split.Symbol} - {split.SplitFactor} - {self.Portfolio.Cash} - {self.Portfolio[self.equity].Price}")
        
        # Accessing Data - Dividends
        dividend = slice.Dividends.get(self.equity)
        if dividend:
            self.Debug(f"{self.Time} >> DIVIDEND >> {dividend.Symbol} - {dividend.Distribution} - {self.Portfolio.Cash} - {self.Portfolio[self.equity].Price}")
            
        # Accessing Data - Delisting
        delisting = slice.Delistings.get(self.equity)
        if delisting:
            delistingType = {0: "Warning", 1: "Delisted"}.get(delisting.Type)
            self.Debug(f"{self.Time} >> DELISTING >> {delisting.Symbol} - {delistingType}")
            
        # Accessing Data - Symbol Changed Event
        symbolChangedEvent = slice.SymbolChangedEvents.get(self.equity)
        if symbolChangedEvent:
            self.Debug(f"{self.Time} >> SYMBOL CHANGED >> {symbolChangedEvent.OldSymbol} -> {symbolChangedEvent.NewSymbol}")

Example Applications

The US Security Master enables you to accurately design strategies harnessing any core corporate actions. Examples include the following strategies: