Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Get data from Yahoo! Finance for Microsoft, Dow Chemical, and Johnson & Johnson for 2014-2019 and save them to .csv files. Then, create a Python

Get data from Yahoo! Finance for Microsoft, Dow Chemical, and Johnson & Johnson for 2014-2019 and save them to .csv files. Then, create a Python program that finds the portfolio weights on the three stocks that minimize the portfolio volatility given that the expected return on the portfolio has to be at least 9%.

You will need to first calculate the log returns for each stock. Then, second, you will need to calculate the covariances between each pair of stocks. Third, use these covariances to create the covariance matrix in Python. You can use the average return over the time period as the expected return. (This is a silly assumption, but we need to get numbers from somewhere!)

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Personal Finance

Authors: Jeff Madura

6th Edition

0134082915, 9780134082912

More Books

Students also viewed these Finance questions

Question

6. How can a message directly influence the interpreter?

Answered: 1 week ago