LINEAR REGRESSION MODEL USING EVIEWS
Transcript of LINEAR REGRESSION MODEL USING EVIEWS
LINEAR REGRESSION MODEL USING EVIEWS 1
ADESETE AHMED ADEFEMI
LINEAR REGRESSION MODEL USING EVIEWS
ADESETE, AHMED ADEFEMI
APRIL 2017
LINEAR REGRESSION MODEL USING EVIEWS 2
ADESETE AHMED ADEFEMI
LINEAR REGRESSION MODEL USING EVIEWS
Econometrics may be defined as a social science which is concerned with the empirical
measurement and quantitative analysis of economic phenomena which is made possible with
the use of tools of statistics , mathematics and economic theory and decision taken with the
use of different tools of inferences. In other words, econometrics can also be defined as the
empirical analysis of several economic issues which is broken down with the use of an
econometric model and this model finally aids decision making in relation to economic
theory or otherwise depending on the inferences from the model. Econometrics can be
theoretical or applied. Econometrics in general deals with model building. This leads us to the
question that what is a model? And what are the assumptions guiding a model in
econometric? This paper aims to discuss the various assumption guiding a model and also the
violation of this assumptions and how this violations affect a model. Also solution to this
violations would be discussed. All this would be demonstrated using the Eviews 7.0.
“A model therefore, according to Advanced English Dictionary, is defined as a hypothetical
description of a complex entity or process”
Therefore this gives us a clearer picture of what a model is , an econometric model therefore
involves the hypothetical representation of reality into function based on economic theory.
An econometric model helps give a clearer picture of complex economic phenomena and also
aids decision making when subjected to econometric analysis .
A model has both mathematical representation and econometric representation . Let us
consider a simple linear regression model using the simple law of demand . From demand
theory, other factors held constant, there is a negative relationship between quantity demand
LINEAR REGRESSION MODEL USING EVIEWS 3
ADESETE AHMED ADEFEMI
and price, that is, price is the only factor that influences demand and the higher the price of a
commodity, the lower the quantity demanded of that commodity and the lower the price of a
commodity, the higher the quantity demanded of that commodity. Therefore from this, let just
consider the demand for rice in Nigeria adopting the demand theory.
DEMAND FOR RICE
Q = f(P) -----------------------Mathematical representation(model)
Q = α + β(P) + ε ---------------------Econometric model
Q------------Dependent variable or regressand
P------------Explanatory variable or regressor
α------------Autonomous rice demand
ß------------Coefficient of price of rice
ε------------error term
ASSUMPTIONS OF LINEAR REGRESSION MODEL
Linearity: the model is a linear function of its parameter vector β or its explanatory
variable.
Normality: The error term from the regression function must be normally distributed
The mean of the error should be equal to zero
The error term from the regression function should not be serially correlated
The error term from the regression function should be homoscedastic
The model should be free from omitted variable bias
There should be no multicollinearity, that is, there should be no high correlation between
or among the explanatory variables
LINEAR REGRESSION MODEL USING EVIEWS 4
ADESETE AHMED ADEFEMI
PRACTICAL EXAMPLE USING EVIEWS
Now let us consider a practical example :
From the earlier example on the demand for rice
Note: we would be making use of an annual data which range from 1970-2013
Please ensure you have eviews installed on your device.
STEP 1:
Get the data set ready in excel format which would look like this :
YEARS WRP RIM 1970 544.0899 1000 1971 456.8466 6000 1972 486.0543 11000 1973 937.5587 2000 1974 1373.979 4000 1975 816.7586 6000 1976 554.5917 94000 1977 551.4044 446000 1978 650.2489 789000 1979 527.9535 242000 1980 629.7379 394000 1981 702.9055 686000 1982 430.0942 666000 1983 416.3877 903000 1984 385.4647 629000 1985 329.9331 569000 1986 271.2938 462000 1987 285.2688 642000 1988 346.3487 344000 1989 375.6759 164000 1990 327.6236 224000 1991 358.0412 296000 1992 321.4414 440000 1993 272.7124 382000
LINEAR REGRESSION MODEL USING EVIEWS 5
ADESETE AHMED ADEFEMI
1994 319.5891 300000 1995 349.1712 300000 1996 375.8236 350000 1997 353.2384 731000 1998 370.1532 900000 1999 308.2422 950000 2000 254.3951 1250000 2001 225.7056 1906000 2002 253.523 1897000 2003 248.2061 1448000 2004 279.5221 1369000 2005 326.4045 1650000 2006 339.0297 1500000 2007 342.0653 1800000 2008 632.2696 1750000 2009 575.3483 1750000 2010 488.9069 2400000 2011 498.4627 3200000 2012 523.2434 2800000 2013 476.9968 2800000
LINEAR REGRESSION MODEL USING EVIEWS 6
ADESETE AHMED ADEFEMI
STEP TWO
Navigate to the eviews package installed on your device and open the package
The eviews environment looks like this :
LINEAR REGRESSION MODEL USING EVIEWS 7
ADESETE AHMED ADEFEMI
STEP THREE
Create a new workfile by clicking File/New/Workfile on the toolbar of the Main window of
eviews
Then a workfile range appears which looks like this:
LINEAR REGRESSION MODEL USING EVIEWS 8
ADESETE AHMED ADEFEMI
Click on OK after the date has been set and workfile name has been specified and this
would take us to the workfile environment which includes constant C and resid
LINEAR REGRESSION MODEL USING EVIEWS 9
ADESETE AHMED ADEFEMI
STEP FOUR
LINEAR REGRESSION MODEL USING EVIEWS 10
ADESETE AHMED ADEFEMI
Now, the workfile environment is ready which specifies that there are 44 observations , let us
load our data into eviews. There are different method of doing this , we can use the drag and
drop method , import method or the copy and paste method. Lets try the copy and paste
method.
Navigate to the microsoft excel file in which the data is located and open it
Copy the data
After the data has been copied , go and paste it in the eviews work environment
The workfile environment should appear like this:
LINEAR REGRESSION MODEL USING EVIEWS 11
ADESETE AHMED ADEFEMI
STEP FIVE
The data has been successfully loaded , the next step here is to proceed to estimation of the
equation by navigating via Quick/Estimate equation that is by clicking on quick then
navigate to estimate equation .
You should have something like this :
LINEAR REGRESSION MODEL USING EVIEWS 12
ADESETE AHMED ADEFEMI
In the box , model to be estimated should be typed including the constant , c
Note : log of the variables considered is what would be estimated
log(rim) c log(wrp)
LINEAR REGRESSION MODEL USING EVIEWS 13
ADESETE AHMED ADEFEMI
LINEAR REGRESSION MODEL USING EVIEWS 14
ADESETE AHMED ADEFEMI
Since we are using the ordinary least square method to estimate the above equation then there
is no need to change the method except other method would be considered , proceed to click
OK
Here is the result of the equation. The model above proves that from the conventional law of
demand , demand is a function of price other factors held constant . In other article how to
determine significance of factors , interpretation of the Adjusted R2 , F statistic would be
discussed.