In this simple Stata tutorial, we present a few steps to Download World Bank Data using Stata within Stata. The world bank data can be easily downloaded in Stata which is ready for analysis without any prior efforts required to manage, create, merge or append to other files. Also, one can download the data for one country as a time series data, a panel data for the world as whole or for selected few countries’s sample. Lets begin the tutorial and follow the steps along to get your data in Stata and begin the first analysis.
- Download the World Bank Data Download ado file. This ado file is named -wbopendata- in Stata. You can -findit wbopendata- to search and install it. We share the few lines of codes which helps us find, download and install the ado file directly in Stata.
search wbopendata, all
net describe wbopendata, from(http://fmwww.bc.edu/RePEc/bocode/w)
net install wbopendata.pkg
- Once installed, then begin to read the help file for -wbopendata- so we know the basics of how to use the ado file. The following code gives the the contents of the -wbopendata- help in Stata.
- We can then open the -wbopendata- in Stata as a dialogue box to download the data directly in Stata.
- In this dialogue box, we can see few options to select. These are either to select a variable, or select a country or groups of countries or select a theme (group of variables). As we are downloading a simple time series data for all variables for Pakistan only, hence, we will only select Pakistan from the downlist of countries or type PAK in the box in front of this downlist. It dictate the wbopendata to use data for Pakistan only for download.
- We can then also select a variable or theme (group of variables) to download the data about it.
- Next, we select the checkbox in front of Import Data as Long Format. It helps us get all the data in long format instead of wide format which is conventional World Bank style of storing data.
- Once we are done with country or selected variables, then we click on OK button. The download begins and we can track its progress on the Stata progress bar shown at the left bottom of Stata.
- Once data is downloaded, Stata will take a few moments to present the data. We can then use the Data for analysis.
It is thus very easy to Download World Bank Data using Stata. You can watch the video tutorial of this guide below: