# Stock Price Reactions to Earnings Announcements

### 5.2. Finding Earnings Data

Secondly, the earnings data from the company must be gathered, FMP has the ability to pull earnings results going back roughly 20 years depending on the company, this is more than adequate for this software as the calculations will not solely be using the earnings reports from one company or industry. After the earnings dates, eps, and expected eps is pulled from the API call, it is stored in an earningsData object which possessed the date, eps, expected eps, revenue, and expected revenue for that specific earning call. A function in the software called FMPfindStockEarningData() returns a list of all earningsData object for further analysis.

### 5.3. Calculations And Results

The final and most complex area of the software’s processes include the calculations and results formulations functions. This is where all of the company’s stock data is computed to better understand the price action after the company exhibits an earnings call. This function formulates 10 main calculations listed in Table 1.

The first set of calculation would be used to identify stocks that are projected to beat earnings based off the historical trend. Using a strategy like this is not recommended and most likely will not be very accurate as a trend does not always correlate to the company actually being profitable.

Table 1: Table shows the calculations that are to be performed on the SP500 dataset.

Calculation Description
A. % of (+) beat earnings when the stock is in an uptrend
B. % of (-) missed earnings when the stock is in a downtrend

These calculations find the likelihood of a stock’s price movement based on the company’s earnings results. Stocks that perform well (or beat earnings) are typically looked at by investors as buying opportunities, and thus the security’s price increases. This is not always the case however, and the results of this will be shown later in the report. Sometimes, investors project the stock to beat earnings by more than others and in turn find even some positive earnings results bearish. This can cause major stockholder to sell their shares and bring the price down.

Calculation Description
C. % of (+) beat earnings, where price increases from open
D. % of (+) beat earnings, where price increase from the previous day’s close
E. % of (-) missed earnings, where price decreases from open
F. % of (-) missed earnings, where price decreases from the previous day’s close

The final set of calculations the software is performing, looks at all parts of the stock and its trend. It identifies the likelihood of a stock price increasing due to (+) beat or (-) missed earnings, while it is in a specific type of trend reflective of the earnings direction. This can be used by investors to find stocks in an uptrend or downtrend, who also want to play the earnings direction and try to profit from it.

Calculation Description
G. % of (+) beat earnings, where price increases from open and is in a current uptrend
H. % of (+) beat earnings, where price increases from the previous day’s close and is in an uptrend
I. % of (-) missed earnings, where price decreases from open and is in a current downtrend
J. % of (-) missed earnings, where price decreases from the previous day’s close and is in a downtrend

## 6. The Results

The results here are caclulated based on the data gathered and calculated during SP500 companyies' earnings.

### 6.1 Test Results - Calculation 1

Table 2: Table shows the results of the calculation on AAPL stock price going back 20 years.

Stock Scanned: AAPL

Caclulated using the code on: https://github.com/cybertraining-dsc/fa20-523-336/blob/main/project/project.py API key required.

• Total Data Points Evaluated: 10,000
• Total Beat Earnings: 64 (84.2%)
• Total Missed Earnings: 12 (15.8%)
• Calculation Total in Seconds: 1
Calculation Description Result
A. % of (+) beat earnings when the stock is in an uptrend 84%
B. % of (-) missed earnings when the stock is in a downtrend 0%
C. % of (+) beat earnings, where price increases from open 40.63%
D. % of (+) beat earnings, where price increase from the previous day’s close 67.19%
E. % of (-) missed earnings, where price decreases from open 50%
F. % of (-) missed earnings, where price decreases from the previous day’s close 75%
G. % of (+) beat earnings, where price increases from open and is in a current uptrend 39.68%
H. % of (+) beat earnings, where price increases from the previous day’s close and is in an uptrend 66.67%
I. % of (-) missed earnings, where price decreases from open and is in a current downtrend 0%
J. % of (-) missed earnings, where price decreases from the previous day’s close and is in a downtrend 0%

### 6.2 Test Results - Calculation 2

Table 3: Table shows the results of the calculation on AAPL, MSFT, TWLO, GE, and NVDA’s stock price going back to their IPO. This caclulation gathers more data.

Stocks Scanned: AAPL, MSFT, TWLO, GE, NVDA

For the second results scan, 5 popular companies within the S&P500 were picked, in the technology and energy sector. This first test was meant to get a baseline of calculations of strong stocks in this index and get an estimated calculation time for the operation. After running the first calculation, the results were as followed. The total calculation time clocked in at just over 8 seconds for the 5 stock calculations (1.6 seconds/stock). At this rate, calculating all 500 stocks from the S&P500 should take around 13:20 minutes.

From the 5 stocks scanned, there were over 36,170 data points evaluated, 222 earnings beats, and 98 earnings misses. When stocks are in a current uptrend, the company is expected to beat earnings expectations 78.6% of the time, and when the stock is in a current downtrend the company is expected to miss earnings 59.7% of the time. This means that if the stock is in an uptrend, investors predicting a company will beat earnings would be correct more than 3/4 of the time. Of the stocks evaluated, if the company beat earnings, the price would increase from the open 42.3% of the time, and increase from the past close 61.3% of the time. Additionally, if a company missed earnings expectations, the stock price closed below the open 59% of the time, and below the previous close 60% of the time. This leads to the prediction that investors are more concerned about the company missing earnings, rather than the company beating earnings. The company missing earning expectations is more detrimental to the stock price than the company beating earnings predictions. Lastly, of these 5 stocks, the price increases from open, when earnings have been beat and the stock is in an uptrend, 43.5% of the time. Notice since we added the uptrend filter on this scan, it results a higher calculation than calculation C but only slightly. Stocks that are in an uptrend and beat earnings, increase from the previous close 63.9% of the time. Again, these results are only slightly higher than calculation D. If the stock is in a downtrend and the company misses earnings, the stock price will decrease from the open 60.1% of the time and will decrease from the previous close 54.3% of the time. This means that stocks that are in a downtrend and miss earnings, tend to actually have a spike up in premarket hours (before open 9:30amET) and then crash further throughout the day, since the decrease from open % is greater than the decrease from past close %.

Caclulated using the code on: https://github.com/cybertraining-dsc/fa20-523-336/blob/main/project/project.py API key required.

• Total Data Points Evaluated: 36,170
• Total Beat Earnings: 222 (69.38%)
• Total Missed Earnings: 98 (30.62%)
• Calculation Total in Seconds: 8
Calculation Description Result
A. % of (+) beat earnings when the stock is in an uptrend 78.60%
B. % of (-) missed earnings when the stock is in a downtrend 59.74%
C. % of (+) beat earnings, where price increases from open 42.34%
D. % of (+) beat earnings, where price increase from the previous day’s close 61.26%
E. % of (-) missed earnings, where price decreases from open 59.18%
F. % of (-) missed earnings, where price decreases from the previous day’s close 60.2%
G. % of (+) beat earnings, where price increases from open and is in a current uptrend 43.46%
H. % of (+) beat earnings, where price increases from the previous day’s close and is in an uptrend 63.87%
I. % of (-) missed earnings, where price decreases from open and is in a current downtrend 60.87%
J. % of (-) missed earnings, where price decreases from the previous day’s close and is in a downtrend 54.35%

### 6.3 Full Results - Calculation 3

This calculation find the test results based all stocks in the SP500.

The final results scanned all stocks in the S&P500 and took roughly 17 minutes (1023 seconds in total) to complete. This was one of the things that originally was surprising as the first scan pointed toward the full calculations taking less time than it did. The total data points scanned totaled 3.7 million. From the results gathered on the full results pull, the changes between the first test scan and the full scan were identified. The calculation result percentages seemed to average out and begin to navigate towards the 50% (random) mark, although there were a few scan results that yielded some potential advantage across the board.

Caclulated using the code on: https://github.com/cybertraining-dsc/fa20-523-336/blob/main/project/project.py API key required.

• Total Data Points Evaluated: 3,704,001
• Total Beat Earnings: 20,789 (62.3%)
• Total Missed Earnings: 12,577 (37.7%)
• Calculation Total in Seconds: 1023 (17 minutes)
Calculation Description Result
A. % of (+) beat earnings when the stock is in an uptrend 61.6% (-17% difference)
B. % of (-) missed earnings when the stock is in a downtrend 34.54% (-25.2% difference)
C. % of (+) beat earnings, where price increases from open 51.8% (+9.46% difference)
D. % of (+) beat earnings, where price increase from the previous day’s close 56.74% (-4.52% difference)
E. % of (-) missed earnings, where price decreases from open 50.92% (-8.26% difference)
F. % of (-) missed earnings, where price decreases from the previous day’s close 56.92% (-3.28% difference)
G. % of (+) beat earnings, where price increases from open and is in a current uptrend 52.84% (+9.38% difference)
H. % of (+) beat earnings, where price increases from the previous day’s close and is in an uptrend 57.68% (-6.19% difference)
I. % of (-) missed earnings, where price decreases from open and is in a current downtrend 53.76% (-7.11% difference)
J. % of (-) missed earnings, where price decreases from the previous day’s close and is in a downtrend 58.48% (-4.13% difference)

Although these results tend to show more randomness than the 5 scanned in the results of Calculation 1 in Section 6.1, there are a few scans that could yield a profitable and predictive strategy for investors, and/or provide some insight into what the price of a security may do. One area where the software is still able to predict events is in scan A, where we are evaluating the probability that the company will beat earning solely based on what the stock price trend is doing. If we only looked while investing in S&P500 stocks, an investor would be able to assume the company will beat earnings 61.6% of the time if the stock is above the 20 and 50 period moving averages. Of these times, the stock price will increase from the past close 57.68% of the time.

## 7. Conclusion

To conclude, as more and more companies are evaluated in the software’s calculations, the chance of unusual and unique events increase. Theoretically, if a company outperforms their expected earnings and shows number better than what financial advisors predict the company to earn, investors should be encouraged to buy more shares in the company and in turn drive the price of the security higher. Sometimes however, stock prices act in the opposite effect during earnings times as large hedge funds and corporations sell off large volume shares of stock to fear other investors into selling. This can snowball the stock price down to where large institutions can repurchase massive amount of those shares again. This is usually refered to as market manipulation. (In a sort of dollar cost averaging method) Because of this, and many other market manipulation activities that occur on stock markets across the globe, positive earnings announcements do not always yield positive buyer sentiment and a price increase. Concluded from this research, it can be said that the strongest correlation to a stock beating earnings estimates, is the price trend of the security. If the stock is in a current uptrend, the chance of that security beating earnings is over 60% (based on SP500 Stock Calculations) With this, earnings announcements are something that many investors should and could look at while investing both short term and long term in companies, however, to develop a truly profitable trading strategy, more work and analysis would need to be conducted. The market moves in ways that few can acurately explain, and as more stocks are scanned and analyzed, the randomness and factor of luck began to show.

## 8. Acknowledgements

Thank you to Dr. Gregor Von Laszewski, Dr. Geoffrey Fox and all other AI staff that helped with the planning and teaching of the I423 class during the COVID-19 pandemic through the fall 2020 semester. This class helped to better understand areas of big data and the science behind it. Additionally, the class gave participants the ability to learn more about their own chosen topic. Thank you.