Macro Earnings
Introduction
Goal: combine sell side earnings analysis with top-down macro using data science techniques
This analysis will be updated on a quarterly basis and is a work-in-progress. All errors are my own. Comments and suggestions are welcome and can be sent to aguilar-mike@outlook.com
Please connect with me on LinkedIn https://www.linkedin.com/in/mike-aguilar-econ/
Data
Data Description
Earnings data:
- Sizes: Large (SP500), Mid (SP400), Small (SP600)
- Sectors: Communication Services, Consumer Discretionary, Consumer Staples, Energy, Health Care, Industrial, Materials, Real Estate, Technology, Utilities
- Granularity: Data is only collected at the sector level; i.e. I don’t have company level information.
- Fields: EBIT Margins (Margins), Sales per Share (Revenues)
- Horizon: LTM (Note: I use LTM rather than quarterly data since my data source doesn’t report all of the needed metrics across all sectors on a quarterly basis).
- Frequency: calendar quarter
- History: 2000->, with missing data at the beginning of the panel for some sectors
Margins
Margins are presented in a q/q growth rate.
Margin Growth by Sectors
# A tibble: 11 × 8
Sectors min q5 q25 q50 q75 q95 max
<chr> <dbl> <dbl> <dbl> <dbl> <dbl> <dbl> <dbl>
1 CommService -0.236 -0.0778 -0.0267 -0.00560 0.0180 0.0777 0.236
2 ConsDisc -0.308 -0.0944 -0.0181 -0.000607 0.0218 0.0944 0.258
3 ConsStaple -0.320 -0.0872 -0.0151 -0.00127 0.0142 0.0772 0.691
4 Energy -20.5 -0.942 -0.108 -0.0132 0.0809 0.524 2.47
5 Financial -0.146 -0.0897 -0.0263 0.000536 0.0312 0.0864 0.322
6 HealthCare -0.556 -0.0814 -0.0134 0.00105 0.0259 0.0915 0.392
7 Industrial -0.221 -0.0889 -0.0148 0.00576 0.0193 0.0869 0.134
8 Material -0.543 -0.133 -0.0372 0.00539 0.0421 0.132 1.18
9 RealEstate -0.384 -0.104 -0.0258 -0.00203 0.0226 0.0964 0.539
10 Tech -2.52 -0.0979 -0.0132 0.00554 0.0324 0.118 3.26
11 Utilities -0.136 -0.0566 -0.0159 0.00218 0.0232 0.0856 0.355
Margin Growth by Size
# A tibble: 3 × 6
Size q5 q25 q50 q75 q95
<dbl> <dbl> <dbl> <dbl> <dbl> <dbl>
1 400 -0.0742 -0.0227 0.00184 0.0259 0.0741
2 500 -0.0519 -0.0125 0.00199 0.0187 0.0693
3 600 -0.0791 -0.0246 -0.00105 0.0232 0.0805
Margins Time Series
Size Classes
Comm. Services
Cons. Disc.
Cons. Staples
Energy
Financials
Health Care
Industrials
Materials
Real Estate
Tech
Utilities
Revenues
Revenues are presented in a q/q growth rate.
Rev Growth by Sectors
Rev Growth by Size
Revenue vs Margins
Avg Growth
Large bubbles for SP500, medium bubbles for SP400, small bubbles for SP600.
Click on sectors in margin to highlight.
Recent Growth
Large bubbles for SP500, medium bubbles for SP400, small bubbles for SP600.
Click on sectors in margin to highlight.
Current Rev/Margin State
I separate each sector’s revenues and margins into 4 “states”: i) Rev Growth >0, Margin Growth >0, ii) Rev Growth >0, Margin Growth <0, iii) Rev Growth <0, Margin Growth <0, iv) Rev Growth <0, Margin Growth >0.
For each sector I identify it’s current state and compute the the historical relative frequency (“Prob”) of being in the state, along with the duration (in quarters) of each spell of that state.
….something wrong. how can 500 health care have 0 prob and positive length of stay?
Spot checking. Energy sp500 in excel. Not mathcing. The quad assignment in temp looks good. ProbCurrentQuad in calc is working, but not matching the table output.
Transition to New State
#To Do: # Make graph bigger # Allow hover on zero bars # Color the SizeIndices differently in bar chart # Not sure if dropping last obs is always appropriate when adding 1 to time # hover labels have too many decimals .