Time series analysis

Analysis of top 4 tech stocks (Apple, Microsoft, Google, Amazon)

Prashant Kumar
3 min readJun 15, 2021

I believe the stock market is one of the most exciting places we know. Here either can grow your wealth exponentially or you lose your wealth. You need to be both, book smart and street smart to be in the wealth-making category. Steet smartness comes with experience, but book smartness you can gain anytime. As you become book smart, you can analyze the share performance , trends from the near past.

In this project, I have done trend, highs/lows, correlation analysis of Google, Microsoft, Apple, Amazon. I got the data from the public data source, Kaggle. I used python programming language to perform the whole analysis.

I started with importing different packages like Pandas, Numpy, plotly. Post importing all my packages and imported data sheets of the respective tech companies for the analysis.

In my first analysis, I plotted the closing price of each stock.

closing price.

From the plot, we can clearly see that the closing prices are rising steeply since 2017, which means that the stock prices are rising steeply since the given time. Amazon and Microsoft seem to be leading this trend as their price rise are the steepest.

In the next analysis, I plotted the monthly closing time trend of amazon.

Monthly closing time trend.

In our next analysis, I plotted the correlation between different stocks.

closing time correlation between stocks.

From the correlation plot, I found a very interesting fact. The closing time trend of Microsoft and Amazon is highly correlated.

The correlation fact is verified from the above tree plot as well.

In the next analysis, I did a risk analysis on Apple share.

Normal distribution of apple price change of a day.

In this plot, we can clearly see that the apple price change distribution is under the normal distribution.

Its 1st std:1.1871377131421237

2nd Std: 2.3742754262842474

3rd std: 3.561413139426371.

Std values of apple share

This means that the 99.17%(3rd std) times the apple daily share price would be ranging between +,-3.56.

This was my analysis of the 4 stocks. I hope you guys liked it. Thanks for your patience and time.

--

--

No responses yet