CITE THIS NOTEBOOK: Equity analytics in the Equities Data Store by Jonathan Kinlay. Wolfram Community 21 2022.
The first release of the equities entity store product will contain around 2,000-2,500 equities, including at least 1,000 active stocks listed on the NYSE and NASDAQ exchanges and a further 1,000-1,500 delisted securities. All of the information described below will be available for each equity and, in addition, the historical data will include quarterly fundamental data.
The other major component of the store will be analytics tools, including single-stock analytics functions such as those illustrated here. More important, however, is that the store will contain advanced analytics tools designed to assist the analyst in the construction of optimized equity portfolios and in the development and backtesting of long and long/short equity strategies.
The other major component of the store will be analytics tools, including single-stock analytics functions such as those illustrated here. More important, however, is that the store will contain advanced analytics tools designed to assist the analyst in the construction of optimized equity portfolios and in the development and backtesting of long and long/short equity strategies.
Performance Metrics
Performance Metrics
Equities Entity Store
Equities Entity Store
Equities Entity Store - A Brief Review
Equities Entity Store - A Brief Review
The Equities Entity Store applies the object-oriented concept of Entity Stores in the Wolfram Language to create a collection of equity objects, both stocks and stock indices, containing current and historical fundamental, technical and performance-related data. Also included in the release version of the product will be a collection of utility functions (a.k.a. “Methods”) that will facilitate equity analysis, the formation and evaluation of equity portfolios and the development and back-testing of equities strategies, including cross-sectional strategies.
In the pre-release version of the store there are just over 1,000 equities, but this will rise to over 2,000 in the first release as delisted securities are added to the store. This is important in order to eliminate survivor bias from the data set.
In the pre-release version of the store there are just over 1,000 equities, but this will rise to over 2,000 in the first release as delisted securities are added to the store. This is important in order to eliminate survivor bias from the data set.
In[]:=
EntityList[EntityClass["Equities","Stock Indices"]]allStocks=EntityList[EntityClass["Equities","Stocks"]];Length@allStocksallStocks//Short
Out[]=
Out[]=
1003
Out[]//Short=
,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,868,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,
Equity Properties
Equity Properties
In[]:=
Out[]=
,,,,,
Company Information
Company Information
In[]:=
Out[]=
SymbolNYSE:ABT,ExchangeNYSE,Start Date,Company,SectorMedicalDevices,SICCode3841
Fundamental Information
Fundamental Information
The release version of the Equities Store will contain a full set of fundamental data, both current and historical.
Out[]=
MarketCap1.71742×,PERatio20.3811,EarningsPerShare4.8118,EBITDA12424000000
11
10
Index Memberships
Index Memberships
In[]:=
Out[]=
DOW30False,SP500True,Russell 1000True
Price-Volume
Price-Volume
In[]:=
Out[]=
Volume4902826,AverageVolume3Month5.33126×,AdjustedClose98.07,High52Week142.6,Low52Week93.25,Average200Day111.618,Average50Day101.297,FractionalChange200Day-12.1376,FractionalChange50Day-3.18568,Volatility250Day26.2141,Volatility50Day29.7507,Volatility20Day37.7968
6
10
Historical Data
Historical Data
Historical data includes daily and and monthly price and returns series, as well as historical performance information.
In[]:=
Out[]=
Daily PricesTimeSeries
,Daily ReturnsTimeSeries,Monthly PricesTimeSeries,Monthly ReturnsTimeSeries,Monthly PerformanceTimeSeries
Performance Data
Performance Data
The Performance property shows current performance information for the stock, over periods ranging from inception to 1 month. Performance metrics include alpha and beta, information ratio, relative price and autocorrelation, amongst others.
In[]:=
Out[]=
A monthly series of performance tables is included in the Historical Data property, which can be used for cross - sectional portfolio construction and strategy development . For example, the performance data for ABT for the month of December 1995 was as follows:
In[]:=
Out[]=
Entity Store Methods - Performance Analytics
Entity Store Methods - Performance Analytics
The PerformanceAnalytics function provides a detailed analysis of a returns time series, including metrics such as the compound annual return, semi-deviation, maximum drawdown, Sharpe and Calmar ratios. The function can be applied to time series of any frequency and provides a summary analysis in addition to a breakdown by year.
In[]:=
tsABT=["Historical Data"]["Daily Returns"]
Out[]=
TimeSeries
Summary Analytics
Summary Analytics
We can obtain summary analytics for the entire time series:
In[]:=
Dataset[First@PerformanceAnalytics[tsABT],DatasetTheme->{"AlternatingRowColumnBackgrounds",LightBlue,LightOrange},MaxItems->{26,1}]
Out[]=
Analytics by Year
Analytics by Year
Alternatively, we can obtain a more detailed breakdown of performance by year: