ACTL3301/5301: Quantitative Risk Management, Term 2 2022 – Assignment 1 Due: 11:30 PM on Sunday, 24 July 2022
Assignments are to be submitted via Turnitin (on the course webpage in Moodle).
Skills to Develop
This assignment provides you with an opportunity to apply techniques you have learnt in the course lectures to a business task involving data. In addition, your skills in understanding/applying advanced research works (including the text and any additional reference material you consider) will be developed via this assignment. Communication of the results of your investigation and analysis is also an important skill to be developed.
Copyright By PowCoder代写 加微信 powcoder
Background
Since the recent nancial crisis, Gaussian copula has been criticized for its incapability of cap- turing tail dependence, which may lead to a signicant underestimation of the tail risk. In real world scenarios, we usually know much more about marginal distributions than we do about the dependence structure. Sklar’s theorem provides us with a powerful tool to couple up marginals using copulas. Applying the theorem, we can conduct an analysis of tail risk with respect to dierent dependence structures.
By following the steps below, you will generate samples of dierent dependence structures and study how tail risk is inuenced:
1. Download historical daily stock prices of . (AAPL) and Alphabet Inc. (GOOG) from Yahoo Finance for the time period from 01 January 2010 to 01 June 2022. We will use the daily adjusted closing prices.
2. Calculate the daily return series as the logarithmic dierences between stock prices of two consecutive days. Formally, with St denoting the stock price of date t and St−1 denoting that of date t − 1, the return rate of date t is calculated as
Xt = ln St . St−1
Denote by XA and XG the return rates of AAPL and GOOG, respectively. The return rates XtA,XtG at each date t can be viewed as a sample of XA,XG.
3. One dollar invested in a stock at date t − 1 becomes eXt at date t. The potential loss is thus given by
Lt =1−eXt.
Denote by LA and LG the losses of the investments of one dollar in the two stocks, respectively.
4. In an equally weighted portfolio, the values of all stocks are the same. Suppose that our equally weighted portfolio only consists of AAPL and GOOG. The loss per dollar of this portfolio is
L = 1 LA + LG . 2
In case of any questions, please contact Mr. Chen at for further clarication.
5. In this very rst step, we assume that the stock prices of AAPL and GOOG are independent of each other, i.e. XA is independent of XG. Using the historical stock prices, estimate VaRα (L) and ESα (L). Please use both 0.95 and 0.99 for α.
6. In the second step, we apply the Gaussian copula model to couple up XA and XG. Thus, we need to simulate
(U ,U )∼CGa, 12ρ
where the correlation coecient ρ can be approximated by the sample correlation coecient ρˆ. Plot the simulated samples of (U1,U2) and observe the dependence structure. Then we are going to apply Sklar’s theorem with empirical marginal distribution functions to convert
̃A ̃G ̃A ̃G (U1,U2) to X ,X . Estimate VaRα (L) and ESα (L) using X ,X .
7. As mentioned in the background, Gaussian models fail to capture tail dependence in practice. A generalization to remedy this shortcoming is by making use of variance mixture structure. In Topic 3, we learnt that
√⊺ μ+ WAZ∼td(ν,μ,Σ=AA),
where W is a positive random variable, independent of Z and following an inverse gamma distribution with degree of freedom ν, namely,
1 1 W∼IG 2ν,2ν .
8. Now we proceed to simulate VaRα (L) and ESα (L) assuming that the return rates XA, XG obey the t-copula. In the rst step, we need to simulate
where Σ is approximated by
(U,U)⊺∼Ct , 12 ν,Σ
ˆ 1 ρˆ Σ = ρˆ 1 .
There are two ways to do this. We could start from the mixture structure in step 7 to obtain t2 (ν, 0, Σ) random vectors and then convert them so that the marginals become uniformly distributed. The other way is to apply packages in R directly. In the next step, we apply Sklar’s theorem again with empirical marginal distribution functions. Visualize how the two dimensions are related by drawing a scatter plot. In this assignment, we consider degrees of freedom ν = 3, 10, 10000, respectively. What do you observe when the degree of freedom ν approaches innity?
9. Compare the VaRα (L) and ESα (L) values that you obtained using independence copula (step 5), Gaussian copula (step 6), and t-copulas (step 8) to the empirical values. Which model gives the best estimation for the risk measures? Summarize your ndings in tables or graphs.
10. Last, vary the correlation coecient ρ to be 10 evenly spaced values from −0.999 to 0.999, and repeat the above simulations for VaRα (L) (you do NOT need to worry about ESα (L) here) using these new values of ρ. Plot the estimates of VaR0.99 (L) against ρ and comment on your observations.
In addition to writing R code, you are required to compose a written report. In particular, your report should describe your methodology in detail, and present the results clearly. You are also required to include your programming code in the appendix of your report.
1 Assignment submission procedure
1.1 Report: Turnitin submission
You must submit multiple les: 1) a report of no more than 5 pages (excluding cover page, appendix); 2) your cleaned data for analysis; 3) your R code. Make sure that your results are replicable by running the code. Please name the submitted les using the following pattern: zID_FirstName_LastName. Also, you must have a cover page in your report with your name and student number.
Assignments must be submitted via the Turnitin submission box that is available on the course Moodle website. As long as the due date is still future, you can resubmit your work; the previous version of your assignment will be replaced by the new version. Turnitin reports on any similarities between the student’s cohort’s assignments, and also similarities to other sources (such as the internet or all assignments submitted all around the world via Turnitin). Note that any misleading statement will be sanctioned with 0 marks, and possibly with a report to the School Student Ethics Ocer for academic misconduct in extreme cases. More information is available at: https: //student.unsw.edu.au/turnitin. Please read this page, as we will assume that you are familiar with its content.
Please note that when an assessment item had to be submitted by a pre-specied submission date and time and was submitted late, the School of Risk and Actuarial Studies will apply the following policy. A penalty of 25% of the mark the student would otherwise have obtained, for each full (or part) day of lateness (e.g., 0 day 1 minute = 25% penalty, 2 days 21 hours = 75% penalty). Students who are late must submit their assessment item to the LIC via e-mail. The LIC will then upload documents to the relevant submission boxes. The date and time of reception of the e-mail determines the submission time for the purposes of calculating the penalty
You need to check your document once it is submitted (check it on-screen). We will not mark assignments that cannot be read on screen.
Students are reminded of the risk that technical issues may delay or even prevent their sub- mission (such as internet connection and/or computer breakdowns). Students should then allow enough time (at least 24 hours is recommended) between their submission and the due time. The Turnitin module will not let you submit a late report. No paper copy will be either accepted or graded.
In case of a technical problem, the full document must be submitted to your LIC before the due time by e-mail, with explanations about why the student was not able to submit on time. In principle, this assignment will not be marked. Only in exceptional circumstances, an assignment that was submitted by e-mail before the due time may be marked. This must be come with a valid reason, and at the discretion of the Lecturer in Charge.
1.2 Plagiarism awareness
Students are reminded that the work they submit must be their own. While we have no problem with students discussing assignment problems if they wish, the material students submit for as- sessment must be their own. In particular, this means that any R code you present is from your own computer, which developed by yourself, without reference to any other student’s work.
While some small elements of code are likely to be similar with other students performing the same task, big patches of identical code (even with dierent variable names, layout, or comments Turnitin picks this up) will be considered as plagiarism. The best strategy to avoid any problem is not to share bits or pieces of code with others outside your group.
Students should make sure they understand what plagiarism iscases of plagiarism have a very high probability of being discovered. For issues of collective work, having dierent persons marking the assignment does not decrease this probability.
Students should consult the Write well; Learn deeply website and consult the resources pro- vided there. In particular, all students should do the quiz about plagiarism to make sure they know how to avoid any issue. For instance, did you know that sharing any part of your work with other students (outside your group) before the deadline is already considered as plagiarism?2
Yes, that’s right, just sending it, even if the the third party promises not to copy, is already plagiarism in the UNSW policy!
程序代写 CS代考 加微信: powcoder QQ: 1823890830 Email: powcoder@163.com