Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Explain the function of each step in Python, what does the code attempts to achieve? import pandas as pd import seaborn as sns import numpy

  1. Explain the function of each step in Python, what does the code attempts to achieve?

import pandas as pd

import seaborn as sns

import numpy as np

import matplotlib.pyplot as plt

df = pd.read_csv('/Users/qidong/loansmall.csv', low_memory=False)

df.head()

sns.distplot(loan_amount)

2. The expected return for stock A is 10%, and stock B is 5%, the volatility (standard deviation) of return of stock A is 10%, and stock B is 5%, the covariance between Stock A and Stock B is 25%.

What is the return variance for Stock A and Stock B?

What is the covariance covariance matrix of Stock A and B?

Part A Use mathematics and number calculation without EXCEL

Assume that the investor wants to minimize the variance of the portfolio. Use optimization (first order derivative of objective function =0) to calculate the weight for minimum variance portfolio.

Assume that the investor wants to maximize the expected return of the portfolio. How much money should he should put in Stock A and Stock B?

Assume that the investor wants to maximize the risk adjusted expected return of the portfolio, and the risk adjusted return for the investor is equal to the epected return minus the variance. How much money should he should put in Stock A and Stock B?

Part B Use EXCEL to answer the following questions:

Assume that the investor wants to minimize the variance of the portfolio. Use optimization (first order derivative of objective function =0) to calculate the weight for minimum variance portfolio.

Assume that the investor wants to maximize the expected return of the portfolio. How much money should he should put in Stock A and Stock B?

Assume that the investor wants to maximize the risk adjusted expected return of the portfolio, and the risk adjusted return for the investor is equal to the epected return minus the variance. How much money should he should put in Stock A and Stock B?

3. For a perpetual bond, derive the relationship between change of discount rate and the change of price using Taylar Approximation.

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

Gender And Finance

Authors: Ylva Baeckström

1st Edition

103205557X, 978-1032055572

More Books

Students also viewed these Finance questions

Question

Distinguish between hearing and listening.

Answered: 1 week ago

Question

Use your voice effectively.

Answered: 1 week ago