logo

Change in Unemployment Rate Question Answer 2022

   

Added on  2022-10-02

14 Pages2093 Words36 Views
STATS 201/8 Assignment 1
Your Name and ID Number here
Due Date: 3pm Thursday 15th August
## Loading required package: s20x
Question 1
Question of interest/goal of the study
We want to investigate Okun’s law using data from the US economy.
Read in and inspect the data:
okun.df=read.table("okun.txt", header=T)
plot(GDP~Unemp,xlab="% change in unemployment rate", ylab="% change in
GDP",data=okun.df)

Comment on the plot
There is negative relationship between percentage change in GDP and
percentage change in unemployment rate as shown in the pattern above.
Fit a simple linear model, including model checks
okun.fit=lm(GDP~Unemp,data=okun.df)
plot(okun.fit,which=1)
normcheck(okun.fit)

cooks20x(okun.fit)
summary(okun.fit)

##
## Call:
## lm(formula = GDP ~ Unemp, data = okun.df)
##
## Residuals:
## Min 1Q Median 3Q Max
## -1.64968 -0.47865 -0.03645 0.42858 2.38799
##
## Coefficients:
## Estimate Std. Error t value Pr(>|t|)
## (Intercept) 0.85898 0.04906 17.51 <2e-16 ***
## Unemp -1.81749 0.12278 -14.80 <2e-16 ***
## ---
## Signif. codes: 0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
##
## Residual standard error: 0.7258 on 217 degrees of freedom
## Multiple R-squared: 0.5024, Adjusted R-squared: 0.5001
## F-statistic: 219.1 on 1 and 217 DF, p-value: < 2.2e-16
confint(okun.fit)
## 2.5 % 97.5 %
## (Intercept) 0.7622829 0.955676
## Unemp -2.0594876 -1.575490
Plot the data with your model superimposed over
it.
plot(GDP~Unemp,xlab="% change in unemployment rate", ylab="% change in
GDP",data=okun.df)

End of preview

Want to access all the pages? Upload your documents or become a member.

Related Documents
Model parameter are tested for statistical
|14
|3949
|14

Forecasting Time Series Assignment 2022
|12
|1735
|7

Linear Modeling Question and Answer
|12
|1549
|9

Loading Required Package Assignment
|20
|3180
|36

Environmental Data Analysis - Assignment
|5
|1407
|16

OLS and LASSO Regression Models for NFL Data
|12
|1021
|69