the ols estimation of a basic gravity model€¦ · interpretation of results . regression analysis...

16
The OLS Estimation of a basic gravity model Dr. Selim Raihan Executive Director, SANEM Professor, Department of Economics, University of Dhaka

Upload: others

Post on 03-Jul-2020

2 views

Category:

Documents


0 download

TRANSCRIPT

Page 1: The OLS Estimation of a basic gravity model€¦ · Interpretation of results . Regression Analysis • Regression analysis studies the conditional prediction of a dependent (or endogenous)

The OLS Estimation of a basic gravity model

Dr. Selim Raihan Executive Director, SANEM

Professor, Department of Economics,

University of Dhaka

Page 2: The OLS Estimation of a basic gravity model€¦ · Interpretation of results . Regression Analysis • Regression analysis studies the conditional prediction of a dependent (or endogenous)

Contents

I. Regression Analysis

II. Ordinary Least Square (OLS)

III. OLS assumptions

IV. Interpretation of OLS regression

V. Applying OLS in gravity estimation

VI. Simple and compound hypothesis testing

VII. Interpretation of results

Page 3: The OLS Estimation of a basic gravity model€¦ · Interpretation of results . Regression Analysis • Regression analysis studies the conditional prediction of a dependent (or endogenous)

Regression Analysis

• Regression analysis studies the conditional prediction of a dependent (or endogenous) variable y given a vector of regressors (or exogenous variables) x, E[y|x]

• The classical regression model takes the form of:

– A stochastic model: y = E [y|x] + µ , where µ is the stochastic disturbance term

– A parametric model: E[y|x]=f(x,β), where f() is a specified function and β is a vector of parameters to be estimated

– A linear model in parameters: f() is a linear function, therefore: E[y|x] = x’β ; where x’ is the vector of exogenous variables and β is the vector of coefficients

Page 4: The OLS Estimation of a basic gravity model€¦ · Interpretation of results . Regression Analysis • Regression analysis studies the conditional prediction of a dependent (or endogenous)

Ordinary Least Square (OLS) estimator : Assumptions

• The OLS estimation follows the assumptions of Classical Linear Regression Model:

I. Linear regression model

II. Explanatory variables are fixed in repeated sampling

III. Zero mean value of disturbance

IV. Homoscedasticity or equal variance of the error term

V. No autocorrelation between the disturbances

VI. Zero covariances between error term and explanatory variables

VII. The number of observations n must be greater than the number of parameters to be estimated

VIII. Variability in the explanatory variables

IX. The regression model must be correctly specified

X. There is no perfect multicollinearity

Page 5: The OLS Estimation of a basic gravity model€¦ · Interpretation of results . Regression Analysis • Regression analysis studies the conditional prediction of a dependent (or endogenous)

Ordinary Least Square (OLS) estimator

Page 6: The OLS Estimation of a basic gravity model€¦ · Interpretation of results . Regression Analysis • Regression analysis studies the conditional prediction of a dependent (or endogenous)

OLS in stata

• To run a simple OLS regression, type:

– reg dependent_var independent_variables, options

– The options may include:

• robust : it is recommended to use robust option as it may handle the issue of the heterogeneity of unknown form.

• cluster: apply the cluster option when there is potential correlation between groups. Specify the cluster option at the appropriate level.

– Apply cluster option to the most aggregated level of variable in the model. For example, In a model including city, state and country, cluster with country.

Page 7: The OLS Estimation of a basic gravity model€¦ · Interpretation of results . Regression Analysis • Regression analysis studies the conditional prediction of a dependent (or endogenous)

Interpretation of OLS regression

Model Dependent

Variable

Explanatory

Variable

Interpretation of the Coefficient (β)

(Holding all other things constant)

Level form regression

y = β0 + β1x + µ

y x On an average, one unit increase in x will

lead to β1 unit of change in y.

Log-Linear model

ln(y) = β0 + β1x + µ

ln(y) x On an average, If x increases by one unit, y

will increase by (100* β1) percent

Lin-Log model

y = β0 + β1 ln(x) + µ

y ln(x) On an average, if x increases by one percent,

y will increase by (β1/100) units of y

Log-Log model

ln(y) = β0 + β1 ln(x) + µ

ln(y) ln(x) On an average if x increases by one percent,

y will increase by β1 percent

Log-Linear Model With

Dummy (θ):

ln(y) = β0 + β1x + θD + µ

ln(y) θD On an average, if the dummy switches from 0

to 1, y will increase by [exp(θ) – 1]

percentage

Page 8: The OLS Estimation of a basic gravity model€¦ · Interpretation of results . Regression Analysis • Regression analysis studies the conditional prediction of a dependent (or endogenous)

Hypothesis Testing

• A statistical hypothesis is an assumption about a population parameter. Hypothesis testing refers to the formal procedures to accept or reject statistical hypotheses.

• Hypothesis testing about individual regression coefficients:

– If we invoke the assumption that the errors are normally distributed with mean zero and a constant variance then w can use the t test to test a hypothesis about any individual partial regression coefficients:

– Let’s suppose our null and alternative hypotheses are:

• Ho : βj = C

• Ha : βj ≠ C

• Where, C is a constant value acquired from previous studies, common knowledge or prior assumption.

Page 9: The OLS Estimation of a basic gravity model€¦ · Interpretation of results . Regression Analysis • Regression analysis studies the conditional prediction of a dependent (or endogenous)

Hypothesis Testing • Our test statistic is:

– The test statistic follows a t distribution with N-K degrees of freedom.

– Where, N is the number of observations, K is the number of parameters and α is the level of significance.

– In case of two tail test the value of the critical t would be tα/2,N-K

• Acceptance/Rejection Rule:

– If the calculated t (tj) is greater than the critical t (tα/2,N-K), then we reject the null hypothesis

– In practice, one does not have to assume a particular value of α to conduct hypothesis testing. One can simply use the p value to see whether the coefficient is statistically significant or not:

• If p < .001 – the coefficient is statistically significant at 1 percent level

• If p < .05 - the coefficient is statistically significant at 5 percent level

• If p < .01 – the coefficient is statistically significant at 10 percent level

Page 10: The OLS Estimation of a basic gravity model€¦ · Interpretation of results . Regression Analysis • Regression analysis studies the conditional prediction of a dependent (or endogenous)

Hypothesis Testing

• Testing the Overall significance of the sample regression: • To check for joint significance of the complete set of regressors we use global F test:

• Null hypotheses Ho: All the coefficients of the model are jointly or simultaneously equal to zero

• Alternative hypothesis Ha: Not all the coefficients of the model are simultaneously equal to zero

– In a k variable model:

• yi = β1x1 + β2x2 + β3x3 + …… + βkxk + µi

• After some manipulations we find:

• Which is:

Total Sum of Squares (TSS) = Explained Sum of Squares (ESS) + Residual Sum of Squares (RSS)

Page 11: The OLS Estimation of a basic gravity model€¦ · Interpretation of results . Regression Analysis • Regression analysis studies the conditional prediction of a dependent (or endogenous)

Hypothesis Testing

• Now, it can be shown that, under the assumption of normal distribution of µi and the null hypothesis that β1 = β2 = β3 = . . . . . = βk = 0, the variable

• Which is distributed as the F distribution with K - 1 and N – k degrees of freedom.

• Acceptance/Rejection rule:

• Here Fα,(k – 1. N – k) is the critical F value at the α level of significance and (k – 1) is the numerator degrees of freedom and (n – k) is the denominator degrees of freedom.

• If F > Fα,(k – 1. N – k) , reject H0; Otherwise do not reject it.

• Alternatively, if the p value of the calculated F is sufficiently low, one can reject H0 .

Page 12: The OLS Estimation of a basic gravity model€¦ · Interpretation of results . Regression Analysis • Regression analysis studies the conditional prediction of a dependent (or endogenous)

Applying OLS in Gravity Model Estimation

• Let’s consider a simple gravity model:

• Let’s consider a gravity model:

xij = β0 + β1 contigij + β2 common_langij + β3 ln (distanceij) + β4 ln(GDPi) + β5 ln(GDPj) + β6 lpii + β7 lpij + β8 landlocki + β9 landlockj + β10 islandi + β11 islandj + β12 ln(cost_export)j + β12 ln(cost_import)j + µij

i is the exporting country, j is the importing country

Where, xij = bilateral import of country j from country i

• contig = (dummy) whether the two countries have a common border

• common_lang = (dummy) whether two countries have common language

• distanceij = distance between country i and j (in log)

• GDP = GDP of the country (in log)

• lpi = logistic performance index of the country, Over all (1= low to 5 = high)

• landlock = (dummy) whether the country is landlocked

• island = (dummy) whether the country is an island country

• cost_export = cost of export for country i (US$ per container)

• cost_import = cost of import for country j (US$ per container)

Page 13: The OLS Estimation of a basic gravity model€¦ · Interpretation of results . Regression Analysis • Regression analysis studies the conditional prediction of a dependent (or endogenous)

Regression result

Page 14: The OLS Estimation of a basic gravity model€¦ · Interpretation of results . Regression Analysis • Regression analysis studies the conditional prediction of a dependent (or endogenous)

Interpretation of the regression result

• Looking at the F statistics, it is evident that, all the regressors are not simultaneously zero.

• The R2 is .71 : about 71 percent of the total variability of the dependent variable is explained by the explanatory variables considered in the model. It shows that, the model has quite high explanatory power.

Page 15: The OLS Estimation of a basic gravity model€¦ · Interpretation of results . Regression Analysis • Regression analysis studies the conditional prediction of a dependent (or endogenous)

Interpretation of the regression result • Looking at the p values of the coefficients of the regressors, we see that, all the

coefficients are highly significant except the variable i_landlocked.

• Interpretation of the coefficients:

– If the distance between country i and j increases by 1 percent, bilateral import of country j from country i will decline by 1.25 percent (holding all other thins constant).

– Countries having common borders do 230 percent higher trade between them compared to countries without common borders.

– If the countries have common language then the trade between the countries will be 181 percent higher than countries without common language

– If the GDP of the exporting country increases by 1 percent, the export to the partner country will increase by more than 1 percent.

Page 16: The OLS Estimation of a basic gravity model€¦ · Interpretation of results . Regression Analysis • Regression analysis studies the conditional prediction of a dependent (or endogenous)

Interpretation of the regression result

• 1 percent increase in the cost of export of the exporting country will lead to a .67 percent decline in the export of that country.

• If the LPI of the exporting country improves by 1 point, the export will increase by 111 percent.

• If the exporter country is a landlocked country, then the export will be 2.95 percent lower compared to non-landlocked countries. However, this variable is statistically insignificant.

• If the time to export increases by 1 day,