Strength of Relationship
The plot shows that there is a positive relationship between P/B and ROE. However, we may want to know how strong this relationship is from a quantitative perspective. The strength of the relationship between ROE and P/B can be determined by looking at the R-squared of the regression, which is a measure of how good the fit of the model is. In this exercise, we regress P/B on Return on Equity and output the summary of the model.
Also, for use in the next exercise, store the intercept in a
and beta in b
.
This exercise is part of the course
Equity Valuation in R
Exercise instructions
- Call
summary()
on the regression object. - Store the intercept term in
a
. - Store beta in
b
.
Hands-on interactive exercise
Have a go at this exercise by completing this sample code.
# Regression model
reg <- lm(p_bv ~ roe, data = cons_disc)
# Regression summary
summary_reg <- ___
summary_reg
# Store intercept
a <- ___
a
# Store beta
b <- ___
b