Assignment 1. the gravity model of trade: do size and distance matter

Assignment 1. The gravity model of trade: do size and distance matter for the exports of (fill in name of your country)?

Assignment 1 is due on Monday 22 October 2012 at the beginning of class.

The assignments are done in groups of two students. For assignment 1, every country can be taken only by one group. Send me a mail ([email protected]) with your country and your names in the subject line: ES11221 firstname LASTNAME of student 1, firstname LASTNAME of student 2. It’s first-come, first-serve. Here’s the list of countries and students so far.

Start by reading:

Krugman, Obstfeld, and Melitz (2012), Chapter 2.
the rules for written work
the section on APA Style from a standard textbook on academic writing (Glenn et al., 2004, pp. 652-679, or Kirszner and Mandell, 2011, chapter 35, pp. 236Ð263)
line_of_best_fit.pdf. If you took a course on quantitative methods, review the sections in your quantitative methods textbook on scatter plots and linear regression (an excellent introduction is: Freedman, Pisani, & Purves (2007), Ch. 7 and Ch. 12 section 1).
the document on how to typeset math (pdf)
(optional) the STA101_Using_R.pdf and the sections on installing R from STA101_Getting_started.pdf
I recommend that you print the documents and keep them in your course file.
The gravity model of trade (Krugman, Obstfeld, and Melitz (2012), equation 2-2 p. 43) predicts that trade increases with the partner country’s GDP: the bigger your trade partner’s GDP, the more you trade with that partner country. The model also predicts that trade decreases with the distance to the partner country: the further away your trade partner, the less you trade with that partner country. In this assignment, you’ll test these hypotheses by estimating the gravity equation.

Pick a country (but not the US) from this list.

First, you have to collect the data.

Bilateral trade data with the ten biggest trading partners are in the Country Trade Profiles from:
United Nations. (2011). 2011 International Trade Statistics Yearbook. New York: United Nations ( ).
To keep things simple, we’ll use exports rather than total trade (exports + imports) to test the gravity model. Nominal GDP data are available from:
International Monetary Fund. (2011). International Financial Statistics Yearbook 2011. Washington, DC: International Monetary Fund. Available in print in the VUB library.
As the bilateral exports data are in millions of USD, you have to convert nominal GDP also to millions of USD. You can find the appropriate exchange rate in International Monetary Fund (2010), too. In the paper, show your work to convert GDP to millions of dollars for one country. All trade and GDP data should be for the same year.

Distance data are available from Cite the source as:
Centre d’études Prospectives et dÕInformations Internationales (CEPII) (2011). Geodesic distances. Retrieved on (write the date) from
The file dist_cepii.xls contains distances between countries. The downloaded file is a compressed file (; double-click to expand it to dist_cepii.xls. The dist_cepii.xls file is a spreadsheet file in Microsoft Excel format, that can be opened by Excel and by most other spreadsheet programs (such as OpenOffice Calc or Apple’s Numbers). The distances are in kilometers. The country codes are three-letter ISO codes (e.g., Belgium is BEL). The list of ISO country codes is here. Your paper should have a table (table 1) with the relevant data for the top-10 export destinations: country, exports (USD), GDP of destination country (USD), and distance to destination country (km). Put the table on a separate page at the end of the paper. Dumping some spreadsheet output on a separate page is not appropriate; the table should be carefully designed, using APA style. The table should be numbered and captioned, units of measurement should be given, numbers should be rounded, sources should be documented in a note to the table.

Second, make a scatter plot (figure 1) that focuses on size (GDP) as a determinant of trade. It has GDP (as a percent of the GDP of all top-10 export destinations) on the horizontal axis, and exports (as a percent of the exports to all top-10 export destinations) on the vertical axis, like figure 2-3 on p. 44.

You can draw the scatter plot by hand on squared paper, or use a spreadsheet program (LibreOffice Calc, Numbers, or Excel) or statistical software (like SPSS, TSP, Stata, Eviews, Gretl, or R; see the link to the R scripts at the end of this paragraph; if you know R, you can easily adapt the scripts). In any case, make sure the axes are labelled (variable and units of measurement) and the points are labelled with the country names or codes. It’s OK to handwrite the axis labels and point labels. Here is an example: figure 1 (pdf) for the US (generated using the R script. Here’s the US data set.

Next, estimate the coefficients of the gravity equation (equation 2-2 in Krugman et al. (2012), p. 43):
Tij = A Yia Yjb/Dijc
The slope coefficients (a and b) of this linearized equation are elasticities: b measures by how many percent trade increases when the partner country’s GDP increases by one percent; c measures by how many percent trade decreases when the distance to the partner country increases by one percent. This can be seen by taking the partial derivatives (check your math for business and economics course) of the gravity equation with regard to Yj and Dij, or—without using calculus— by using the following approximation. From
Tij = A Yia Yjb/Dijc
it follows that approximately
percentage change of Tij = percentage change of A + a (percentage change of Yi) + b (percentage change of Yj) – c (percentage change of Dij)
The first two terms of the right-hand side are zero, so we obtain that approximately:
percentage change of Tij = b (percentage change of Yj) – c (percentage change of Dij)
If we control for distance, we obtain:
percentage change of Tij = + b (percentage change of Yj)
or, solving for b:
b = (percentage change of Tij) / (percentage change of Yj)
That is, b is the elasticity of trade with regard to the partner country’s GDP.
Similarly, If we control for the partner country’s GDP, we obtain:
percentage change of Tij = – c (percentage change of Dij)
or, solving for c:
-c = (percentage change of Tij) / (percentage change of Dij)
which is the elasticity of trade with regard to the distance. In your paper, it suffices to say that the coefficients b and c are elasticities of trade with regard to GDP of the partner country and distance to the partner country; you don’t have to repeat the explanation above.

Here’s how to estimate the elasticities b and -c. Make the gravity equation linear in the parameters by taking logarithms of both sides:
logTij = log A + a logYi + b logYj-c logDij
To find estimates of b and c, compute the new variables z = logTij, x1 = logYj, and x2= logDij. Estimate the linear equation:
z = constant + b x1 -c x2
Estimate this equation (find the coefficient estimates for b and c) using multiple regression analysis. Make sure that at least one of the two students in your group knows what multiple regression analysis is and knows how to estimate regression coefficients. This can be done using a spreadsheet program (OpenOffice Calc, Numbers, or Excel) or—preferably—statistical software (like SPSS, TSP, Stata, Eviews, Gretl, or R; see the link to the R scripts at the end of this paragraph; if you know R, you can easily adapt the scripts). Report the equation as explained in line_of_best_fit.pdf. The y-intercept of the equation (representing the estimate of log A + a logYi) is not interesting so you don’t have to discuss it, but carefully report the meaning of the slope coefficients b and c (remember: they are elasticities). Skip the hypothesis tests on the coefficients (t-statistics) and R-squared. Here is an example of the R script to generate the scatter plot and estimate the linearized gravity equation for the US. Here’s the US data set.

The report should have the format set out in my rules for written work: a full report (introduction, middle, end; about 300-600 words), prededed by a brief abstract (max 120 words). Find two appropriate JEL (Journal of Economic Literature) Classification Codes describing the subject of your paper. Most economists use JEL Classification Codes to attach standardized subject descriptors to their papers. For a list see JEL Classification Codes. At the end of the abstract, include within brackets the JEL Classification Codes, something like this: (JEL C210, L620). Start the main text with a general introduction (no header) briefly introducing the gravity model, explaining how you will test it, and which data sources you’ll use. In the next paragraph, briefly describe the data (table 1). Then discuss the scatter plots and the coefficients of correlation. Include figures 1 and 2 at the end of the paper. The References section should contain at least the data source and Krugman et al. (2012) (to which you should refer in your paper). Document all sources using the author-year citation method; this also holds for data sources where the author is an instititutional author.

Start on time. If you run into trouble, ask me for help.

Pay for Essay
Calculate your paper price
Pages (550 words)
Approximate price: -

Why Work with Us

Top Quality and Well-Researched Papers

We always make sure that writers follow all your instructions precisely. You can choose your academic level: high school, college/university or professional, and we will assign a writer who has a respective degree.

Professional and Experienced Academic Writers

We have a team of professional writers with experience in academic and business writing. Many are native speakers and able to perform any task for which you need help.

Free Unlimited Revisions

If you think we missed something, send your order for a free revision. You have 10 days to submit the order for review after you have received the final document. You can do this yourself after logging into your personal account or by contacting our support.

Prompt Delivery and 100% Money-Back-Guarantee

All papers are always delivered on time. In case we need more time to master your paper, we may contact you regarding the deadline extension. In case you cannot provide us with more time, a 100% refund is guaranteed.

Original & Confidential

We use several writing tools checks to ensure that all documents you receive are free from plagiarism. Our editors carefully review all quotations in the text. We also promise maximum confidentiality in all of our services.

24/7 Customer Support

Our support agents are available 24 hours a day 7 days a week and committed to providing you with the best customer experience. Get in touch whenever you need any assistance.

Try it now!

Calculate the price of your order

Total price:

How it works?

Follow these simple steps to get your paper done

Place your order

Fill in the order form and provide all details of your assignment.

Proceed with the payment

Choose the payment system that suits you most.

Receive the final file

Once your paper is ready, we will email it to you.

Our Services

No need to work on your paper at night. Sleep tight, we will cover your back. We offer all kinds of writing services.


Essay Writing Service

No matter what kind of academic paper you need and how urgent you need it, you are welcome to choose your academic level and the type of your paper at an affordable price. We take care of all your paper needs and give a 24/7 customer care support system.


Admission Essays & Business Writing Help

An admission essay is an essay or other written statement by a candidate, often a potential student enrolling in a college, university, or graduate school. You can be rest assurred that through our service we will write the best admission essay for you.


Editing Support

Our academic writers and editors make the necessary changes to your paper so that it is polished. We also format your document by correctly quoting the sources and creating reference lists in the formats APA, Harvard, MLA, Chicago / Turabian.


Revision Support

If you think your paper could be improved, you can request a review. In this case, your paper will be checked by the writer or assigned to an editor. You can use this option as many times as you see fit. This is free because we want you to be completely satisfied with the service offered.