# Example 4.6, Participation Rates in 401(k) Plans
# Data set: 401k
# Function for result reporting
source("_report.R")
# Load the data and estimate the model in the background
load("401k.Rdata")
model=lm(prate~mrate+age+totemp, data=data)
dig=c(2,2,3,5,3)
# Describe the model
cat("This example uses the 401(k) pension plan data set in Example 3.3\nIn the previous example, we estimated the model prate = beta0 + beta1 * mrate + beta2 * age + u, where prate is ",
paste(desc[desc[,1]=="prate",2]),
", mrate is ", paste(desc[desc[,1]=="mrate",2]),
" and age is ", paste(desc[desc[,1]=="age",2]),
"\nHere we add a new independent variable, totemp, which is ", paste(desc[desc[,1]=="totemp",2]),
sep="")
# Report results
{
cat("The estimated regression line is")
reportreg(model,dig)
}
# Interpretation
cat("The smallest t statistic in absolute value is that on totemp: ",
printcoef(model,4,dig[4]), "/", printse(model,4,dig[4]), " = ", printt(model,4,dig[4]),
", which is still statistically significant at very small significance levels (The two-tailed p-value for this t statistic is about .001.) Therefore, all the independent variables are statistically significant at very small significance levels",
"\nHowever, the coefficient on totemp is very small in a practical sense. When totemp of a firm grows by 10000, the predicted prate only falls by 10000 * ",
printabscoef(model,4,dig[4]), " = ", 10000*as.numeric(printabscoef(model,4,dig[4])),
" percentage points, a very small effect",
sep="")