联系方式

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

您当前位置:首页 >> OS程序OS程序

日期:2020-11-09 09:41

Department of Economics Applied Econometrics and Data Analysis
Problem Set 3
Due Date: November 6, 2020 by class time.
In this problem set, we will perform some statistical exercises using the same financial data set
that you used in Problem Set 1. The main variables in the data set are the monthly returns of
some stocks and financial assets, as well as the returns of the S&P 500 index, which is a measure
of the returns of the stock market as a whole. We denote the S&P 500 returns as rM.
We will analyze our stock data through the lens of an important model in Financial Economics,
the CAPM model. This model states that the expected rate of return of asset j in excess of the
risk-free return is determined by how its returns covary with the market return, in particular,
E(rj ) ? rf = βj (E(rM) ? rf ) (1)
where rj
is the rate of return of asset j, rf is the rate of return of a risk-free asset (i.e. an asset that
always yields the same return, thus taken to be a constant in CAPM theory), rM is the market
return, and βj =
cov(rj ,rM)
var(rM)
is a measure of how asset j’s returns covary with market returns. We
refer to rj ? rf and rM ? rf as excess returns (returns in excess of the risk-free return). In CAPM,
E(rM) > rf , and thus equation 1 predicts that assets with higher βj will have higher E(rj ).
The intuition behind CAPM is that a stock that tends to vary inversely with the market allows
its owners to diversify risk away from the general market. Investors will thus be willing to buy such
stocks, even if expected returns are relatively low. On the other hand, a stock that strongly covaries
with the market offers little risk-diversification benefit. Investors will thus require a relatively high
return to buy it. In equilibrium, prices will adjust such that the high-β stocks that provide little
insurance against market-wide risk will have high excess returns, and low-β stocks that better
insure against market-wide risks have lower expected excess returns.
We will use fiananceR.dta, and look at the market returns, rM, as well as the the returns of
two stocks: SPDR Gold Shares (GLD) and Morgan Stanley (MS) which we will call rA and rB,
respectively.
Before completing this problem set, it might be helpful to review Lecture 2 slides and code, as
well as Handout 2.
1. Use read.dta13 to load fiananceR.dta Assume the risk-free rate is rf = 0.41% = 0.0041
per month. Generate excess returns variables for the market, SPDR Gold Shares (GLD)
and Morgan Stanley (MS), i.e., create new variables equal to rM ? rf , rA ? rf and to
rB ? rf .
2. Compute the sample variance of (rA, rB, rM), and separately of (rA ?rf , rB ?rf , rM ?rf ).
How do the two sample variance matrices compare? Explain the connection between the
two sample variance matrices, using that rf is a constant.
1
3. Install and load the ggplot2 package. Create two scatterplots using ggplot , one scatterplot
with rA ? rf on the vertical axis and rM ? rf on the horizontal axis, the other
scatterplot with rB ? rf on the vertical axis and rM ? rf in the horizontal axis. Do the
excess returns of the gold shares or of Morgan Stanley seem to be more strongly associated
with market returns? Can you provide an explanation?
? Optional: to make the plots easier to compare, do the following. Install and load
the gridExtra package. Create two scatterplots using ggplot , one scatterplot
with rA ? rf on the vertical axis and rM ? rf on the horizontal axis, the other
scatterplot with rB ?rf on the vertical axis and rM ?rf in the horizontal axis. To
make the two scatterplots easier to compare, force the two scatter plots to have
the same limits for the y-axis using the ylim option for ggplot , choosing limits
that are large enough to include all points for both plots. Save the scatterplots as
plot1 and plot2. Use the command grid.arrange(plot1, plot2, ncol=2)
to plot the two scatterplots side by side. Do the excess returns of the gold shares
or of Morgan Stanley seem to be more strongly associated with market returns?
Can you provide an explanation?
4. Consider the following linear regression specification:
(rjt ? rf ) = αj + βj (rM t ? rf ) + jt (2)
where rjt and rM t are the returns on asset j and on the market in period j, and where αj
and βj are defined by the linear projection of (rjt ? rf ) on a constant and (rM t ? rf ). (It
might be helpful to review Lecture 2 slides and code).
(a) Show that βj
from equation 2 is the same as βj
from CAPM, i.e., that βj defined by
linear projection in equation 2 equals cov(rj ,rM)
var(rM)
. (hint: you should consider rf to be a
constant, and review linear projection with a single regressor.)
(b) Show that, if equation 1 holds, then αj = 0. (hint: E[jt] = 0). Use that result to
explain why, if αj > 0, the asset has a higher expected return than should be possible
under CAPM, and if αj < 0, the asset has a lower expected return than should be
possible under CAPM.
(c) Estimate equation 2 by OLS regression separately for gold and Morgan Stanley shares
using the lm function, then answer:
i. What are your estimated values β?
A and β?
B?
? Optional: use stargazer to make a table of your regression results.
ii. Are you estimated values β?
A and β?
B consistent with your estimated sample
covariances from question 2?
iii. Based on the estimated β?
A and β?
B, which of the two stocks seems to covary
more closely with the market?
iv. Produce the same scatter plots as in Questions 3, but now also overlay
a regression line on each scatterplot by using geom_smooth with option
method="lm" , and with the option SE=FALSE .
v. Based on your results, discuss whether an investor worried about market
volatility should add SPDR Gold Shares (GLD) to her portfolio or add Morgan
Stanley (MS) shares to her portfolio.
2

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