Question: Grab the data using yahoofinancials and convert them into a pandas dataframe. Grab stock data for 5 different stocks from the S&P500 Index and print

Grab the data using yahoofinancials and convert them into a pandas dataframe.

Grab stock data for 5 different stocks from the S&P500 Index and print the first few rows for each of 5 stocks.

Explain why you pick these 5 stocks.

And calculate

Returns from Price Data (for each of the 5 stocks)

Average of Returns (for each of the 5 stocks)

Mode of Returns (for each of the 5 stocks)

Standard Deviation of Returns (for each of the 5 stocks)

Correlation Matrix of Returns (for all of the 5 stocks together)

Note: Please use monthly price data for past 3 years, January 2020 - December 2022.

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!