Hello, dear friend, you can consult us at any time if you have any questions, add WeChat: daixieit

ECMT2130: Financial econometrics

Tutorial 04: Portfolio optimisation in R

We are taking a detour via linear regression this week and we are doing so using R. This is specifically relevant to the literature on testing asset pricing models, our upcoming focus in lectures. It is also contextual background for the univariate time-series econometrics that will be the focus of the second half of this course.

This assignment introduces the use of OLS estimation of simple linear time-series models. You should learn to load data from packages, estimate OLS regressions and be able to identify what the various numbers are in the regression summary output.

Begin by reading a background briefing on the economics behind the regression being done in this assignment.

This assignment introduces you to the following new R skills:

1. loading data from R packages

2. defining linear regression models

3. estimating linear regression models

By working with common macro-economic time series, this assignment introduces the com- plexities introduced by dynamic time series.

 

1    R assignment

1. Download the starting point script for this assignment and set it up in an R project in the usual way.

2. Modify and run the code in the script to answer the various questions in the Canvas quiz (they are also embedded in the comments in the starting point script). Enter your results into the Canvas quiz for this week’s assignment.