CS代考 UG-2022-Notebook-1

Assignment-2-UG-2022-Notebook-1
October 3, 2022
0.1 FNCE30012: Foundations of Fintech – Assignment 2
The aim of this assignment is to build a ‘toy robo-adviser’ that computes, based on a set of external inputs, the optimal portfolio for a person. We will then compare our results to a real world robo- advisor, offered by Six Park*. The assignment builds on the material covered in Weeks 4 to 6, including online material, lectures and tutorials.

Copyright By PowCoder代写 加微信 powcoder

You must complete this assigment by 9 October, 2022 at 11:59pm and submit it through Jupyter Hub.
* Six Park’s robo-advisor has been selected purely for pedagogical reasons and should not be interpreted as promotion or endorsement from the University of Melbourne. This assignment will not require you to follow through with the use of their product or to invest with them.
Important: It is important that you follow the assignment instructions as per “How to submit assignments on JupyterHub” available under Modules/Assessment on Canvas.
Note: The assignment will ask you to follow certain precise instructions such as storing results in predefined variable names, or reading CSV files into dataframes with specific names. Failure to follow these instructions would attract penalty.
Note Write your answers in this notebook only within the provided cells. Do not create additional cells or duplicate/copy existing cells. You may keep a copy of this base notebook as reference to original file and to compare that you haven’t accidentally added cells, duplicated cells or changed the order of these cells. However, note that additional notebooks and copies aren’t marked. Only the notebook named Assignment-2-UG-2022-Notebook-1 will be marked.
Assignment Intended Learning Outcomes 1. Demonstrate knowledge of portfolio theory 1. Assess whether applied portfolio construction conforms with theory and, if not, what impact this will have 1. Demonstrate knowledge of risk preferences 1. Appreciate the key challenges involved with assessing a person’s risk preferences 1. Identify economic, psychological and computational barriers to providing competent financial advice/portfolios 1. Critically evaluate whether robo- advisors are true disruption or mere automation
Assignment skill development 1. Critical thinking! 1. Applying theory into practice 1. Pro- gramming

0.1.1 Predefined Package Imports
import scipy.optimize as sco
import scipy.stats as scs
import numpy as np
import pandas as pd
import yfinance as yf
import matplotlib.pyplot as plt plt.style.use(‘fivethirtyeight’)
%matplotlib inline
%config InlineBackend.figure_format = ‘retina’
0.1.2 Import your additional packages in the cell below
Further imports are not required, but you may use additional packages if you wish.
“””Your own additional imports go here”””
# BEGIN – YOUR CODE GOES HERE
# END – YOUR CODE GOES HERE
0.2 Question 1 (1 mark)
0.2.1 Question 1 – Markdown [1 mark]
Do you agree with Six Park’s claim that all else equal, younger investors are more willing to take risk than older investors? Support your answer with one reason based on portfolio theory, as discussed in class, and a second reason based on the findings of Zilker et al.’s 2020 paper “Age differences in risk attitude are shaped by option complexity.” (Strict) Word limit: 90 words.
Note Write your discussion in the Markdown cell below
0.2.2 WRITE YOUR ANSWER(S) HERE IN THIS CELL
You can use Markdown syntax here.
0.3 Question 2 (1.5 marks)
0.3.1 Question 2 (i) – Markdown [1 mark]
Sign up for advice with Six Park at https://app.sixpark.com.au/assessment. You will need to:
1. ClickGetstarted
2. Enter a name and email address (you do not need to enter your real details if you do not
3. ClickIconfirmandwanttoproceed
4. Select you are investing for Myself and click Continue
5. Select Something else and click Start assessment

You will then be asked 10 assessment questions. Is Six Park’s assessment sufficient to accurately estimate an investor’s level of risk aversion, as required for portfolio separation? Give two reasons to support your answer. (Strict) Word limit: 50 words.
Note Write your discussion in the Markdown cell below
0.3.2 WRITE YOUR ANSWER(S) HERE IN THIS CELL
You can use Markdown syntax here.
0.3.3 Question 2 (ii) – Markdown [0.5 marks]
What is the main reason that robo-advisors, like Six Park, do not use machine learning algorithms to estimate a person’s level of risk aversion? (Strict) Word limit: 50 words.
Note Write your discussion in the Markdown cell below
0.3.4 WRITE YOUR ANSWER(S) HERE IN THIS CELL
You can use Markdown syntax here.
0.4 Question 3 (0.5 marks)
0.4.1 Question 3 (i) – Markdown [0.25 marks]
Enter in the following as your answers to Six Parks’ assessment questions.
1. 18-25 years
2. Highly Stable
3. More than 30%
4. $500,000 or more
5. $1 million or more
6. More than 20 years
7. Invest more money in the markets
8. I want to take high risks…
9. Mostly concerned with potential gains on the investment
10. I am highly experienced… 11. ClickShowrecommendation
Select Prefer Sustainable?. You should receive advice for the Sustainable Aggressive Growth portfolio. Assume Six Park does not consider any of the recommended assets as risk-free. Complete the below table with the asset allocation of the optimal RISKY portfolio, as advised by Six Park. Each answer should be to 2 decimal places.
Asset name
% of risky portfolio
Emerging Markets % Global Listed Property % Australian Equities % Intl Equities (Unhedged) %
Intl Equities (Hedged) Global Infrastructure

Asset name Bond/Fixed Income
Total Markdown for the table above
% of risky portfolio
| Asset name | % of risky portfolio |
|————————————|———————-|
| Emerging Markets
| Global Listed Property
| Australian Equities
| Intl Equities (Unhedged)
| Intl Equities (Hedged)
| Global Infrastructure
| Bond/Fixed Income
|**Total**
Note Write your discussion in the Markdown cell below
0.4.2 WRITE YOUR ANSWER(S) HERE IN THIS CELL
You can use Markdown syntax here.
0.4.3 Question 3 (ii) – Code [0.25 marks]
Use the target asset allocation for the Sustainable Aggressive Growth portfolio to determine which specific ETFs Six Park is recommending investment in. Find the relevant tickers for these ETFs in Yahoo Finance [note: the ticker provided by Six Park may not match the ticker in Yahoo Finance]. Create a new variable initial_ticker_list, which should be a python list storing the Yahoo Finance tickers you have found as str elements.
[ ]: “””Do not remove this cell.”””
0.5 Question 4 (3 marks)
0.5.1 Question 4 (i) – Code [0.5 marks]
Complete the following tasks in python:
“””Predefined Variables – Do Not Change their Name – Remember to execute this␣ 􏰦→cell once”””
initial_ticker_list = None
“””Populate the variables shown above with appropriate values here”””
# BEGIN – YOUR CODE GOES HERE
# END – YOUR CODE GOES HERE

“””Do not remove this cell.”””
0.5.2 Question 4 (ii) – Code [0.5 marks]
Complete the following tasks in python:
1. Create a new variable risk_free_rate, which should store the mean annualised return of ‘AAA.AX’.
2. Delete only the data on ‘AAA.AX’ from your daily returns dataframe.
3. Create a new variable mean_returns, which should store the mean daily return of each
remaining ETF in your dataframe.
4. Createanewvariablecov_matrix,whichshouldstorethecovariancematrixofeachremaining
ETF in your dataframe.
5. Plot the daily returns time series from each remaining ETF in your dataframe. Ensure the
1. Use the Yahoo Finance API to load daily ETF price data from 1 July 2018 to 30 September 2021 for each of the stocks provided in ticker_list below.
2. Convert the daily price data into daily returns.
3. The output should be stored in a dataframe called df. df should have the following properties:
1. Each column should represent a ticker.
2. Each row should represent a date.
3. Each element/cell in the dataframe should be a daily return. 4. Dates with missing values for daily returns should be deleted.
“””Predefined Variables – Do Not Change their Name – Remember to execute this␣ 􏰦→cell once”””
ticker_list = [‘DJRE.AX’, ‘STW.AX’, ‘VGS.AX’, ‘VGAD.AX’, ‘IFRA.AX’, ‘IAF.AX’,␣ 􏰦→’AAA.AX’]
df = None # Stored Dataframe
“””Populate the variables shown above with appropriate values here”””
# BEGIN – YOUR CODE GOES HERE
# END – YOUR CODE GOES HERE
plot is appropriately labelled.
“””Predefined Variables – Do Not Change their Name – Remember to execute this␣ 􏰦→cell once”””
risk_free_rate = None mean_returns = None cov_matrix = None
“””Do not remove this cell.”””
“””Populate the variables shown above with appropriate values here”””
# BEGIN – YOUR CODE GOES HERE
# END – YOUR CODE GOES HERE

0.5.3 Question 4 (iii) – Code [1 mark]
Complete the following tasks in python:
1. Compute and plot the efficient frontier. Ensure plots are appropriately labelled and that a minimum of 7% is invested into each ETF.
2. Your plot should mark the location of the Sharpe-optimal risky portfolio. It should NOT mark the location of the minimum variance portfolio.
3. Print the asset allocation of the Sharpe-optimal risky portfolio. Do NOT print the asset allocation of the minimum variance portfolio.
4. Create a variable called optimal_allocation. It should be a dictionary which stores {ticker: weight}, i.e., ticker names as keys and their corresponding weights in the sharpe optimal portfolio, rounded to 3 decimal places, as values.
[ ]: “””Do not remove this cell.”””
0.5.4 Question 4 (iv) – Markdown [0.5 marks]
Assume investors follow a mean-variance utility function of the form U = E(r) − 2ασ2, where E(r) denotes the annual expected return, α is the risk aversion coefficient and σ2 is the annual variance. Let y denote the fraction invested in the optimal risky portfolio p. Following portfolio theory, the utility function can then be re-written as: U = (yE(rp) + (1 − y)rf ) − 2αy2σp2. Algebraically, solve for the optimal fraction y∗ that should be invested in the risky portfolio.
Note Write your discussion in the Markdown cell below
0.5.5 WRITE YOUR ANSWER(S) HERE IN THIS CELL
You can use Markdown syntax here.
0.5.6 Question 4 (v) – Code [0.5 marks]
Assume that for all investors α = 2.5. Complete the following tasks in python:
1. Create a variable called weight_risky. It should store the weight (correct to 3 decimal
places) an investor should allocate to the optimal risky portfolio. 6
“””Predefined Variables – Do Not Change their Name – Remember to execute this␣ 􏰦→cell once”””
optimal_allocation = None
“””Populate the variables shown above with appropriate values here”””
# BEGIN – YOUR CODE GOES HERE
# END – YOUR CODE GOES HERE
“””An additional cell, if required”””
# BEGIN – YOUR CODE GOES HERE
# END – YOUR CODE GOES HERE

2. Create a variable called weight_risk_free. It should store the weight (correct to 3 decimal places) an investor should allocate to the risk-free asset.
[ ]: “””Do not remove this cell.”””
0.6 Question 5 (2 marks)
0.6.1 Question 5 (i) – Markdown [0.25 marks]
Re-do the assessment questions, entering in the following as your answers:
1. 18-25 years
2. Highly Stable
3. More than 30%
4. \$75,000 to \$149,999
5. \$1 to \$124,999
6. Within 3 years
7. Sell all of the investments
8. I want to play it safe…
9. Mostly concerned with potential losses on the investment
10. I am highly experienced…
Do NOT select Prefer Sustainable?. You should receive advice for the Conservative Balanced portfolio. Assume that Six Park considers the ‘Cash Yield’ asset to be the only risk-free asset and that their advice is for the optimal complete portfolio. Complete the below table with the asset allocation of the optimal RISKY portfolio, as advised by Six Park. Each answer should be to 2 decimal places.
“””Predefined Variables – Do Not Change their Name – Remember to execute this␣ 􏰦→cell once”””
weight_risky = None weight_risk_free = None
“””Populate the variables shown above with appropriate values here”””
# BEGIN – YOUR CODE GOES HERE
# END – YOUR CODE GOES HERE
Asset name
% of risky portfolio
Emerging Markets % Global Listed Property % Australian Equities % Intl Equities (Unhedged) % Intl Equities (Hedged) % Global Infrastructure % Bond/Fixed Income % Total (ignoring rounding errors) 100%

Markdown for the table above
| Asset name | % of risky portfolio |
|————————————|———————-|
| Emerging Markets
| Global Listed Property
| Australian Equities
| Intl Equities (Unhedged)
| Intl Equities (Hedged)
| Global Infrastructure
| Bond/Fixed Income
|**Total**
Note Write your discussion in the Markdown cell below
0.6.2 WRITE YOUR ANSWER(S) HERE IN THIS CELL
You can use Markdown syntax here.
0.6.3 Question 5 (ii) – Markdown [0.25 marks]
Compare the asset allocations in 4 (iii) and 5 (i) and give two noteworthy observations. (Strict) Word limit: 40 words.
Note Write your discussion in the Markdown cell below
0.6.4 WRITE YOUR ANSWER(S) HERE IN THIS CELL
You can use Markdown syntax here.
0.6.5 Question 5 (iii) – Code [0.25 marks]
Calculate and print the annual return, annual standard deviation, and Sharpe ratio of the optimal risky portfolio, as recommended by Six Park’s asset allocation in 5 (i). They should be stored in variables called return_6, std_6, and sharpe_6, respectively. Each answer should be to 4 decimal places: for example, if the return was 10.23% then the value of return_6 should be 0.1023.
“””Predefined Variables – Do Not Change their Name – Remember to execute this␣ 􏰦→cell once”””
return_6 = None std_6 = None sharpe_6 = None
[ ]: “””Do not remove this cell.”””
“””Populate the variables shown above with appropriate values here”””
# BEGIN – YOUR CODE GOES HERE
# END – YOUR CODE GOES HERE

0.6.6 Question 5 (iv) – Code [0.25 marks]
Calculate and print the annual return, annual standard deviation, and Sharpe ratio of the optimal risky portfolio, as recommended by our asset allocation from 4 (iii). They should be stored in variables called return_opt, std_opt, and sharpe_opt, respectively. Each answer should be to 4 decimal places: for example, if the return was 10.23% then the value of return_opt should be 0.1023.
[ ]: “””Do not remove this cell.”””
0.6.7 Question 5 (v) – Markdown [1 marks]
Based on all you have learned so far, do you believe Six Park’s investment advice is consistent with the principles of portfolio theory? Your answer should make reference to two-fund separation. You should assume that the equivalent sustainable ETFs have identical return characteristics to their non-sustainable counterparts (e.g., that the return characteristics of Sustainable Australian Shares are identical to those of Australian Shares). (Strict) Word limit: 80 words.
Note Write your discussion in the Markdown cell below
0.6.8 WRITE YOUR ANSWER(S) HERE IN THIS CELL
You can use Markdown syntax here.
0.7 Question 6 (2 marks)
0.7.1 Question 6 – Markdown [2 marks]
Assume that obtaining advice from a human financial advisor follows this process:
1. You answer some basic questions
2. Your advisor maps your answers to an investment portfolio based on a set of proprietary
business rules
3. The advisor explains your suggested portfolio and offers to implement the strategy for you
If human advice follows the above process, what is one key similarity and one key difference between Robo-advice and human advice? In your answer, state whether you believe robo-advisors (as they are today) represent true disruption that could revolutionise financial advice, or whether they merely represent automation. (Strict) Word limit: 90 words.
Note Write your discussion in the Markdown cell below 9
“””Predefined Variables – Do Not Change their Name – Remember to execute this␣ 􏰦→cell once”””
return_opt = None std_opt = None sharpe_opt = None
# BEGIN – YOUR CODE GOES HERE
# END – YOUR CODE GOES HERE

0.7.2 WRITE YOUR ANSWER(S) HERE IN THIS CELL
You can use Markdown syntax here.

程序代写 CS代考 加微信: powcoder QQ: 1823890830 Email: powcoder@163.com