联系方式

  • QQ:99515681
  • 邮箱:99515681@qq.com
  • 工作时间:8:00-23:00
  • 微信:codinghelp

您当前位置:首页 >> C/C++编程C/C++编程

日期:2024-03-31 06:26

Subject: C39RF Applied Financial Modelling in Python Case Study 2

Date: Submission deadline: 12th of April, 5pm UK time and 8pm Dubai time, and midnight (23:59) Malaysia time.

Please note the following before you commence the assignment:

? You have to submit a Jupyter Notebook file (with extension ipynb) as well as a script. with the html extension which contains the solutions to the tasks enumerated below. You can download the scripts with both ipynb and html extensions from the Jupyter Notebook.

? You have to download your ipynb and html files showing all your output to the codes in each cell and you upload these files into the Assignment - Case Study 1 Submission.

? You also have to submit all the csv files that contain your data - failing to do so will result in losing marks.

? Please make sure you don’t download data that was discussed in class (lectures and tutori als).

? For all plots you should display a meaningful name for the axes and also give a title and provide a legend. The same applies for histograms and boxplots.

? This assessment is worth 100 marks and it accounts for 50% of your final grade.

? Please remember that only four types of files are allowed to be uploaded onto Canvas/Turnitin: ipynb, html, excel and csv. Make sure you download the files and upload them well before the deadline. Practice downloading the ipynb and html files from the Jupyter Notebook now.

? For each task, 25% of the marks will be awarded for successfully writing up the code, and the rest of the marks (75%) will be given for explaining in-depth the results. If you are asked to discuss for example a plot in 100 words and you only discussed it in 50 words, your mark will reflect that. Of course, the content of your discussion matters primarily and not the length of your discussion.

? Discussions should be provided in a Markdown cell and not in a code cell as comments. Do not provide definitions of statistical and econometrics terms as that will not yield in getting marks.

? Only use code that was used in Lectures and Tutorials. Do not produce a script. using differ-ent coding techniques - otherwise, it will be assumed that external help was utilised.

You have to solve each task to get full marks.

1. Download daily adjusted close price stock market data from Yahoo Finance for the period January 2016 to December 2023 for the two corporations you have used for Case Study 1 (only if you correctly chose the two corporations, otherwise choose new company data). The stock market prices should be for firms from two different industries. You should use a data scraping method. At the same time download the daily prices for the stock market index you used for Case Study 1 as well as the daily VIX index. In a Markdown cell explain which stock prices and index you have downloaded and the rationale for deciding on this particular data set (maximum 100 words). 2 marks

2. Create a new dataframe. with your data. Make sure the index column is not displayed. 2 marks

3. If your data is of the same magnitude, plot a timeline of your four time series (prices) in a single plot. Otherwise plot them separately. Make sure the timeline (date) is visible. Name the axes and give a title. Also provide a legend. Discuss the figure in a Markdown cell in 100 words. 3 marks

4. Save the dataframe. as a csv file. You will have to submit this file along with your Jupyter Notebook ipynb and html files. 1 mark

5. Calculate the daily first differenced/log returns from the prices (or exchange rates, whatever is the case) for your three variables and calculate only the first difference for the VIX index. Check for missing values in your four variables and remove them. Display and inspect the head of the dataset to show there are no missing values. 8 marks

6. Test your four variables for stationarity. Print your results displaying the test statistic, p-values and critical values. Discuss your results in a Markdown cell in maximum 200 words. 10 marks

7. Create a new dictionary with your four variables (returns, and not the prices), then transform. it to a dataframe. and save it as a csv file. You should upload this file to the Assessment page. 6 marks

8. Run a Vector Autoregression (VAR) using the returns. Display the results and discuss these in a Markdown cell in maximum 300 words. Don’t forget to explain the rationale of running a Vector Autoregression model using your variables and what do you expect to see in your data. 6 marks

9. Determine the correct lag order before you re-run your VAR model. Discuss the results in a Markdown cell in maximum 100 marks. Explain the rationale of having to determine the lag order. 3 marks

10. Refit the VAR model with the correct number of lags. Discuss the results in a Markdown cell in maximum 200 words. 4 marks

11. Plot the Impulse Responses and discuss the plots in a Markdown cell in maximum 400 words. Discuss the plots and explain the rationale of determining the impulse responses using the chosen variables. 8 marks

12. Run a Granger Causality test using your four variables (returns). Discuss your results in a Markdown cell in maximum 150 words. Explain the rationale of testing for Granger causal-ity in your chosen variables. 6 marks

13. Download daily adjusted close values for a cryptocurrency (other than Bitcoin or Ethereum) from Yahoo Finance for the period January 2019 - December 2023. This data can be some-thing you have either downloaded for Case Study 1, or something new. Calculate the first differenced log returns, remove missing vales, transform. the data into a dataframe, examine the first 5 and last 5 rows of the data, plot the crypto returns’ series over time and save the data as a csv file. You will have to upload this file to the Assessment. Discuss the plot and explain in a Markdown cell the rationale of downloading this particular cryptocurrency in maximum 150 words. 7 marks

14. Model the volatility for your chosen cryptocurrency returns. Provide relevant figures and save your data as a csv file. Upload the file to the Assessment page. Go through all the steps necessary to be able to run a GARCH model. Discuss your figure(s) and results in light of relevant hypotheses in maximum 300 words. 17 marks

15. Re-download the daily adjusted close values for the period 2000-2019 for your chosen index. Test for the day-of-the-week effect in the index. Go through all the steps necessary to be able to model seasonality. Provide relevant figures and save your data as a csv file, then upload it to the Assessment page. Discuss your figure(s) and results in light of relevant hypotheses in maximum 300 words. 17 marks

Total 100 marks

Don’t forget the following:

? Make sure you show all of the outputs (solutions, plots, etc) before downloading the ipynb and html files.

? Download the ipynb and html scripts and upload them to the Assessment page.

? Upload all the csv files to the Assessment page.





版权所有:留学生编程辅导网 2020 All Rights Reserved 联系方式:QQ:99515681 微信:codinghelp 电子信箱:99515681@qq.com
免责声明:本站部分内容从网络整理而来,只供参考!如有版权问题可联系本站删除。 站长地图

python代写
微信客服:codinghelp