<?xml version="1.0" encoding="UTF-8"?><rss xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:atom="http://www.w3.org/2005/Atom" version="2.0" xmlns:cc="http://cyber.law.harvard.edu/rss/creativeCommonsRssModule.html">
    <channel>
        <title><![CDATA[Stories by Marek Hlavac on Medium]]></title>
        <description><![CDATA[Stories by Marek Hlavac on Medium]]></description>
        <link>https://medium.com/@MarekHlavac?source=rss-bcf2a64a4cae------2</link>
        <image>
            <url>https://cdn-images-1.medium.com/fit/c/150/150/1*FuYmcxD_ywhhqXZycIQGfQ.jpeg</url>
            <title>Stories by Marek Hlavac on Medium</title>
            <link>https://medium.com/@MarekHlavac?source=rss-bcf2a64a4cae------2</link>
        </image>
        <generator>Medium</generator>
        <lastBuildDate>Wed, 02 Dec 2026 23:49:12 GMT</lastBuildDate>
        <atom:link href="https://medium.com/@MarekHlavac/feed" rel="self" type="application/rss+xml"/>
        <webMaster><![CDATA[yourfriends@medium.com]]></webMaster>
        <atom:link href="http://medium.superfeedr.com/" rel="hub"/>
        <item>
            <title><![CDATA[TableMaker for Microsoft Excel: A Macro for Publication-Quality Tables]]></title>
            <link>https://medium.com/@MarekHlavac/tablemaker-for-microsoft-excel-a-macro-for-publication-quality-tables-bf68d27d981c?source=rss-bcf2a64a4cae------2</link>
            <guid isPermaLink="false">https://medium.com/p/bf68d27d981c</guid>
            <category><![CDATA[excel]]></category>
            <category><![CDATA[statistics]]></category>
            <category><![CDATA[ux]]></category>
            <category><![CDATA[macro]]></category>
            <category><![CDATA[presentations]]></category>
            <dc:creator><![CDATA[Marek Hlavac]]></dc:creator>
            <pubDate>Mon, 08 Jan 2018 00:46:56 GMT</pubDate>
            <atom:updated>2018-01-08T00:55:15.615Z</atom:updated>
            <content:encoded><![CDATA[<p>This article introduces <strong>TableMaker</strong>, a <em>Microsoft Excel </em>macro that produces publication-quality tables and includes them as new sheets in workbooks. You can <a href="https://sites.google.com/site/marekhlavac/exceltablemaker">download it from my personal website</a>.</p><p>The macro provides an intuitive graphical user interface that allows for the full customization of all table features. It also allows users to save and load table templates, and thus allows layouts to be both reproducible and transferable. It is distributed in a single computer file. As such, the macro is easy to share, as well as accessible to even beginning and casual users of <em>Excel</em>. Since it allows for the quick creation of reproducible and fully customizable tables, <strong>TableMaker</strong> can be very useful to academics, policy-makers and businesses by making the presentation and formatting of results faster and more efficient.</p><p><strong>TableMaker</strong> was programmed in <em>Visual Basic for Applications </em>(<em>VBA</em>) for <em>Excel</em>, and is contained in a single macro-enabled <em>Excel</em> workbook (extension <strong>.xlsm</strong>). It is open-source, does not require any compilation, and is provided free of charge to both commercial and non-commercial users. As such, the macro is easy to distribute and accessible to even beginning and casual users of <em>Excel</em>. All that is required is the sending or sharing of a single computer file. <strong>TableMaker</strong> is currently only compatible with <em>Microsoft Windows</em> systems.</p><h3>Getting Started</h3><p>To get started with the <strong>TableMaker</strong> macro, users need to open <strong>TableMaker.xlsm</strong>, as well as the “destination” workbook (i.e., the workbook in which they would like to include the new tables), in <em>Excel</em>. Upon opening the file, <em>Excel</em> may issue a security warning stating that “macros have been disabled.” If that is the case, users can enable macros by simply clicking on the adjacent “<strong>Enable Content</strong>” button. They can then create a new publication-quality table by following these instructions:</p><ol><li>Activate the worksheet in front of which the table will be inserted.</li><li>Bring up the <strong>TableMaker</strong> interface by pressing <em>Ctrl+Shift+N</em>. Alternatively, the graphical user interface can be accessed by pressing <em>Alt+F8</em> and running the <strong>Table_Maker</strong> macro.</li><li>Customize the table specifications using the <strong>TableMaker</strong> graphical user interface.</li><li>Click on the green “<strong>Create Table</strong>” button. <strong>TableMaker</strong> will insert a new worksheet that contains the new table.</li><li>If necessary, manually make any additional adjustments to the generated table.</li><li>Fill in the data in the table — either manually or using appropriate <em>Excel</em> functions such as <strong>VLOOKUP</strong> or <strong>HLOOKUP</strong>.</li></ol><h3>Sample Table</h3><p><em>Figure 1</em> shows an example of a publication-quality table that was created using the <strong>TableMaker</strong> macro for <strong>Microsoft Excel</strong>. The table was published in <a href="https://www.russellsage.org/sites/all/files/logan/logan_diversity_chapter2.pdf">Holzer and Hlavac (2014)</a>, and reports some United States labor market statistics from the years 1979 and 2007.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/836/1*Mzh1D7zYX2SUzg588M70iA.png" /><figcaption>Figure 1: Sample table from Holzer and Hlavac (2014)</figcaption></figure><p>The table contains a title, subtitle and a time period. There is one stub entry, labelled “Category”. There are, furthermore, three groupings of columns (“Mean Hourly Wages”, “Employment/Population Ratio” and “Mean Annual Earnings”), each of which contains two columns — one corresponding to the year 1979, and the other one to 2007. The first and the third column groupings feature unit headings that indicate that the amounts are denominated in 2010 U.S. dollars.</p><p>The columns also differ in their formats: Columns containing wage and earnings figures have a “currency” format (as indicated by the adjacent dollar sign), while the column with employment/population ratios has a numeric format. The numbers in the first four columns are rounded off to two decimal places, whereas the earnings figures in the last two columns are rounded off to the nearest dollar. The data are spread across thirty rows, some of which are empty. Below the main body of the table are three lines of notes and one line that indicates the sources of the table’s content.</p><p><strong>TableMaker</strong> allows users to customize each aspect of the table through an intuitive user interface. The next section explains how.</p><h3>Graphical User Interface</h3><p>The <strong>TableMaker</strong> macro provides users with an intuitive and easy-to-navigate graphical user interface. The interface consists of five tabs, in which users can specify a variety of table features. In this section, I describe each of these tabs in detail.</p><h4><strong>Header and Footer</strong></h4><p>On the <strong>Header and Footer</strong> tab, shown in <em>Figure 2</em>, users can choose whether the printed version of the table will include a header or a footer. If they decide to include either of these, <strong>TableMaker</strong> users can type into the appropriate text boxes to specify what text will appear in the header or footer, as well as to choose its position (left, center or right) on the page. Users can also adjust the font type, size and style (bold, italics or underlined).</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/599/1*ce_HPjnCdXmWjlZdv3KeSA.png" /><figcaption>Figure 2: “Header and Footer” tab</figcaption></figure><h4>Title, Subtitle, Time Period</h4><p><em>Figure 3 </em>shows the <strong>Title, Subtitle, Time Period</strong> tab, where users can specify the title, subtitle and the time period of their table. Again, users can adjust the font type, style and size using the provided text boxes and buttons.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/603/1*RhInWBWWtGZD5AK9amqAcQ.png" /><figcaption>Figure 3: “Title, Subtitle, Time Period” tab</figcaption></figure><h4>Rows and Columns</h4><p>The <strong>Rows and Columns </strong>tab (see <em>Figure 4</em>) allows users to specify the number and formatting of rows, columns, stub entries and the data in the table. This tab is composed of three major parts: <strong>Rows</strong>, <strong>Columns</strong> and <strong>Data</strong>.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/604/1*Hg1EyJYRvSrb6fG3HZb7Xw.png" /><figcaption>Figure 4: “Rows and Columns” tab</figcaption></figure><p>In the <strong>Rows</strong> part, <strong>TableMaker</strong> users can specify the number of rows in the table, as well as the number and labelling of stub entries (i.e., columns that usually specify the type of item that the row refers to). Optionally, users can choose to include a row counter and to adjust its width, as well to include a Totals row that would most typically include the sum totals of values in the corresponding table columns.</p><p>In the <strong>Columns</strong> part, users can determine the layout and cell format of the table’s columns. Two options are available: a basic layout specification for relatively simple tables and an advanced layout specification for more complex ones. Section <strong>Layout of Table Columns </strong>describes these two alternatives in detail. Users can also specify the formatting of numeric, currency and percentage cells. In particular, they can decide how many decimal places will be reported, whether to include a thousands separator, and what currency symbol will be used.</p><p>Users can adjust the width of the columns, as well as the width of the buffer columns that separate them. Each column can, furthermore, be optionally indexed by letters in alphabetical order (check box “(a), (b), (c), etc.”) or by increasing numbers (check box “(1), (2), (3), etc.”). Last but not least, users can toggle unit headings — an additional row typically used to report what units are being used in a particular column — either at the upper or the lower level of column headings. Finally, in the <strong>Data</strong> part, users can adjust the font of the data that will be used to fill up the rows and columns of the table.</p><h4>Notes and Sources</h4><p><em>Figure 5</em> reproduces the <strong>Notes and Sources</strong> tab. Here, users can toggle whether notes, footnotes and source annotations should appear below the table, and specify how many lines should be devoted to each. As usual, the font types, styles and sizes can all be adjusted.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/603/1*74OuK3Lo-w7BCN-DE1yYcw.png" /><figcaption>Figure 5: “Notes and Sources” tab</figcaption></figure><p><strong>Page Layout</strong></p><p>Finally, the <strong>Page Layout</strong> tab (in <em>Figure 6</em>) lets users adjust where and how the resulting table will be presented on the page. Users can choose the page orientation of the table (landscape or portrait), decide whether the table should be centered on the page (either horizontally or vertically), or adjust page breaks. Page breaks can be put in automatically, manually after a specified number of items, or the table can be made to fit on a requested number of pages. In addition, <strong>TableMaker</strong> users can choose to include blank rows and columns — from the top and left of the page, respectively — and to exclude some rows and columns from the print area.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/601/1*S-fm7qe-c6aW5uzq8UB_Xw.png" /><figcaption>Figure 6: “Page Layout” Tab</figcaption></figure><h4>Bottom of the GUI</h4><p>Once they have specified its layout using the options in the five tabs, users can insert the resulting table into the current worksheet by clicking on the green “<strong>Create Table</strong>” button at the bottom of the graphical user interface. If needed, <strong>TableMaker</strong> can produce multiple copies of the table, or provide a print preview of the table.</p><p>If users would like to use a particular table template in the future, they can save it as a .<strong>tmt</strong> file using the “<strong>Save…”</strong> button on the lower left-hand side of the window. Later, templates can be retrieved using the “<strong>Load…”</strong> button.</p><p>The “<strong>Restore default”</strong> button will restore all table settings to their default values. <strong>TableMaker</strong> will search for a <strong>default.tmt</strong> template file in its directory, and will load the default values from that file. If <strong>default.tmt</strong> cannot be found, all values will change to a pre-programmed default. This implies that you can set a particular set of values to be the default by saving your template as <strong>default.tmt</strong> in the directory that contains <strong>TableMaker.xlsm</strong>.</p><p><strong>Layout of Table Columns</strong></p><h4>Basic Layout</h4><p>The “<strong>Basic”</strong> layout option allows <strong>TableMaker</strong> users to design relatively simple tables with several identical column groupings. To do so, users can specify two numbers on the <strong>Rows and Columns</strong> tab. The right number indicates how many columns there will be in a single grouping, while the left number indicates how many identical groupings there will be. If the left number is zero, there will be no common heading for the grouping, only headings for individual columns. Users can choose what kind of columns the table will contain:</p><ul><li><strong>G</strong> = general (no particular format),</li><li><strong>N</strong> = numeric,</li><li><strong>$</strong> = currency</li><li><strong>%</strong> = percentage.</li></ul><h4>Advanced Layout</h4><p>For more advanced formatting of the column layout, users can toggle the “<strong>Advanced</strong>” option in the <strong>Layout</strong> part of the <strong>Columns</strong> tab, and edit the text box.</p><p>The text code for each grouping has the following format: <strong>LxR[formats]</strong>, where <strong>L</strong> is equivalent to the left number in basic layout (number of identical groupings) and <strong>R</strong> corresponds to the right number (how many columns in a grouping). <strong>[formats]</strong> is a sequence of characters (<strong>G</strong>, <strong>N</strong>, <strong>$</strong> or <strong>%</strong>) that sets column types, in order from left to right. If there are fewer characters in <strong>[formats]</strong> than there are columns in a given grouping, it is assumed that the rightmost columns are of the type of the last <strong>[formats]</strong> character. If no <strong>[formats]</strong> sequence is given, all columns are assumed to be general. Let us take a look at several examples of advanced column formatting.</p><ul><li><strong>2x3$%N</strong> is illustrated in <em>Figure 7</em>, and stands for two identical groupings of three columns each. The left column has a currency format, the middle column contains percentages, and the right column is numeric.</li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/762/1*NwawwBTHII0s0nDO6sZTIA.png" /><figcaption>Figure 7: Advanced layout — 2x4$%N</figcaption></figure><ul><li><strong>4x2%</strong> represents four identical groupings of 2 columns each. All columns are formatted as percentages. See <em>Figure 8</em>.</li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/981/1*YOfiKun4GV8-LbokJtl_Jw.png" /><figcaption>Figure 8: Advanced layout — 4x2%</figcaption></figure><ul><li><strong>0x5GN</strong>, shown in <em>Figure 9</em>, creates one grouping of five columns, but without a common heading for the columns — the first column is general, and the remaining ones are numeric.</li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/659/1*lj1WXlqScTbG2xh3Lpf1yA.png" /><figcaption>Figure 9: Advanced layout — 0x5GN</figcaption></figure><p>You can write down the above definitions next to each other, separated by spaces, to combine the groupings in a single table (left to right) — e.g., <strong>0x5GN 2x3$%N 4x2%</strong>, as illustrated by <em>Figure 10</em>.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*IFsjUqc3TJasCWV7Qa5tPw.png" /><figcaption>Figure 10: Advanced layout — 0x5GN 2x3$%N 4x2%</figcaption></figure><h3>Practical Example</h3><p>The <strong>TableMaker</strong> macro enables users to create publication-quality tables in three simple steps. First, they can use the graphical user interface to create a basic foundation for the table. Next, users can manually adjust the formatting of the table. In the third and final step, they populate the table’s cells with the appropriate data values.</p><p>This section presents a practical example that illustrates this very straightforward process. In particular, we reproduce the labor market statistics table from <a href="https://www.russellsage.org/sites/all/files/logan/logan_diversity_chapter2.pdf">Holzer and Hlavac (2014)</a> that was presented earlier in <em>Figure 1</em>.</p><h4>Step 1: Create Table</h4><p>First, we use the <strong>TableMaker</strong> macro to create a foundation/skeleton for the table. In our example, we need three groupings that consist of two columns each. The first two columns contain currency values, the middle two contain numeric values, while the rightmost two contain currency values again. We therefore use an advanced layout specified by <strong>1x2$ 1x2N 1x2$</strong>. i shows the resulting foundation table.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/759/1*1T0Npx-kEqqpLWnD2k4UEQ.png" /><figcaption>Figure 11: The foundation/skeleton for a soon-to-be publication-quality table.</figcaption></figure><h4>Step 2: Format Table</h4><p>Next, we need to adjust the formatting of the table created in <em>Step 1</em>. In our case, we manually edit its title, subtitle and time period components. In addition, we edit the stub and column headings, and add an appropriate number of rows to the table. <em>Figure 12</em> presents the well-formatted tables that emerges as a result.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/850/1*aOkN2d-IIDXzvoWyzL_Kyw.png" /><figcaption>Figure 12: Formatted table.</figcaption></figure><p>Of course, some of these adjustments (e.g., specifying the title or subtitle) could have already been made in <em>Step 1</em> using the graphical user interface. It is up to the user to decide at which point to adjust various parts of the table. In practice, if the user expects to create the table only once, adjusting most features manually after creating a very simple foundation is likely to be faster. By contrast, if the user expects to use the same foundation for a table multiple times, it might be more convenient to specify most features using the graphical user interface, and to save the template for future use.</p><h4>Step 3: Populate Table</h4><p>Finally, we populate the table with data. In this example, the data we need are stored in the “<strong>Data for Example</strong>” worksheet in the <strong>TableMaker</strong> workbook. <em>Figure 13</em> shows the first eight entries. The worksheet contains the values of several labor market statistics — mean hourly wages, the employment/population ratio and mean annual earnings — for the years 1979 and 2007. The “Category” column specifies the year, as well as the demographic, geographic or educational group to which the statistics pertain.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/891/1*VcJOprGPGqVSxdcQOSYk8w.png" /><figcaption>Figure 13: Portion of the data that will be used to populate the table.</figcaption></figure><p>To fill the formatted table from <em>Step 2 </em>with data, we can use, for instance, the <strong>VLOOKUP</strong> function. <em>Figure 14</em> contains a close-up that illustrates the use of <strong>VLOOKUP</strong> to populate the table. Once all relevant cells have been populated with the appropriate labor market statistics, we will have reproduced the publication-quality table presented in <em>Figure 1</em>.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/852/1*NrLH8TlKumur-Mk1faqmzg.png" /><figcaption>Figure 14: A close-up to illustrate the use of the VLOOKUP function to populate the publication-quality table.</figcaption></figure><p>In this article, I have introduced the <strong>TableMaker</strong> macro for <em>Microsoft Excel</em>. The macro allows for the quick creation of fully customizable, publication-quality tables. I have showcased the macro’s capabilities by providing an example of a <strong>TableMaker</strong>-generated table from an academic publication. In addition, I have described both basic and advanced options for the formatting of table columns, and demonstrated how users can follow a simple, three-step process to create well-formatted tables.</p><p><strong>TableMaker</strong> represents a versatile tool for the production of high-quality tables in <em>Excel</em>. It provides an easy-to-navigate graphical user interface that allows for the customization of every aspect of the generated tables. In addition, it allows users to save and load table templates, and thus makes all table layouts easily reproducible and transferable.</p><p>All in all, <strong>TableMaker</strong> can offer significant benefits to academics, policy-makers and businesses. It can greatly enhance the speed and efficiency of report creation and presentation, and thus save valuable time that can then be allocated to other productive tasks.</p><p><strong>Note: </strong><em>This text is an abridged and simplified version of an article, published in the </em><a href="https://www.jstatsoft.org/index">Journal of Statistical Software</a><em>, that describes the </em><strong><em>TableMaker</em></strong><em> macro. For a more complete treatment with full academic citations and references, please refer to the </em><a href="https://www.jstatsoft.org/index.php/jss/article/view/v070c03/v70c03.pdf"><em>full article</em></a><em>.</em></p><p>If you use tables created by the <strong>TableMaker</strong> macro, please do not forget to include the following citation in your publications:</p><blockquote>Hlavac, Marek (2016). TableMaker: An Excel Macro for Publication-Quality Tables. Journal of Statistical Software, 70(1), 1–16. doi: 10.18637/jss.v070.c03</blockquote><p><strong>About the author: </strong>Marek Hlavac teaches economics at <a href="https://www.uwcad.it/">UWC Adriatic</a>, an international secondary school in Duino (Trieste), Italy. In addition, he is a research fellow at the <a href="http://celsi.sk/en/">Central European Labour Studies Institute (CELSI)</a> in Bratislava, Slovakia. He holds a Bachelor’s degree in Economics from Princeton University, a Master’s degree in Public Policy from Georgetown University, and a Ph.D. in Political Economy and Government from Harvard University. You can find his personal website <a href="https://sites.google.com/site/marekhlavac/">here</a>.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=bf68d27d981c" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Package “ExtremeBounds” for Extreme Bounds Analysis in R — Part 2: Features and Example]]></title>
            <link>https://medium.com/@MarekHlavac/package-extremebounds-for-extreme-bounds-analysis-in-r-part-2-features-and-example-fd452536b996?source=rss-bcf2a64a4cae------2</link>
            <guid isPermaLink="false">https://medium.com/p/fd452536b996</guid>
            <category><![CDATA[r]]></category>
            <category><![CDATA[statistics]]></category>
            <category><![CDATA[economics]]></category>
            <category><![CDATA[data-science]]></category>
            <category><![CDATA[econometrics]]></category>
            <dc:creator><![CDATA[Marek Hlavac]]></dc:creator>
            <pubDate>Wed, 03 Jan 2018 07:47:39 GMT</pubDate>
            <atom:updated>2018-01-03T07:47:39.874Z</atom:updated>
            <content:encoded><![CDATA[<p><em>The text that follows is an abridged and simplified version of an article, published in the </em><a href="https://www.jstatsoft.org/index">Journal of Statistical Software</a><em>, that describes my </em><strong><em>ExtremeBounds</em></strong><em> R package. </em><a href="https://medium.com/@MarekHlavac/package-extremebounds-for-extreme-bounds-analysis-in-r-part-1-introduction-and-theory-a79409e2bd44"><em>Part 1</em></a><em> introduced the package and explained some econometric theory behind the Blinder-Oaxaca decomposition. Part 2, below, presents specific features of the </em><strong><em>ExtremeBounds </em></strong><em>package, and illustrates their use with an example. For a more complete treatment with full academic citations and references, please refer to the </em><a href="https://cran.r-project.org/web/packages/ExtremeBounds/vignettes/ExtremeBounds.pdf"><em>full article</em></a><em>.</em></p><p>If you use the <strong>ExtremeBounds</strong> package in your research, please do not forget to cite it:</p><blockquote>Hlavac, Marek (2016). ExtremeBounds: Extreme Bounds Analysis in R. Journal of Statistical Software, 72(9), 1–22. doi:10.18637/jss.v072.i09.</blockquote><p>The <strong>ExtremeBounds</strong> package consists of the main function <strong>eba()</strong>, which performs the extreme bounds analysis, as well as of two related methods — <strong>print()</strong> and <strong>hist()</strong> — which produce, respectively, histograms and text output to summarize the estimation results. In this section, I provide an overview of these functions’ capabilities, and highlight features that make <strong>ExtremeBounds</strong> the most versatile of the available EBA estimation tools. Users can obtain a more detailed description of the arguments and output of each function by typing, as appropriate, <strong>?eba</strong>, <strong>?print.eba</strong> or <strong>?hist.eba</strong> into the <strong>R</strong> console.</p><h3>EBA Estimation: Main Function eba()</h3><p>The main function <strong>eba()</strong> performs both Leamer’s and Sala-i-Martin’s versions of extreme bounds analysis using variables from a data frame specified in the function’s argument <strong>data</strong>. The user specifies the dependent variable (argument <strong>y</strong>), the free variables to be included in all regression models (<strong>free</strong>), the focus variables that are of interest (<strong>focus</strong>), as well as the full set of doubtful variables (<strong>doubtful</strong>). Note that the variables included in <strong>focus</strong> must be a subset of those in <strong>doubtful</strong>. If the user does not provide any focus variables, <strong>eba()</strong> will assume that all doubtful variables are of interest to the researcher.</p><p>It is often more convenient to specify the model variables through a single <strong>formula</strong> argument. The <strong>eba()</strong> function allows the user to pass on a multiple-part formula that specifies the dependent, free, focus and doubtful variables. These variables, along with the functional form of the model, are passed on to the <strong>formula</strong> argument in an object of class <strong>“Formula”</strong>, as implemented by the <strong>Formula</strong> package by Achim Zeileis and Yves Croissant. The model formula takes the following most general form: <strong>y ~ free | focus | doubtful</strong>. If all doubtful variables are of interest (i.e., all are focus variables), the user can pass on <strong>y ~ free | focus</strong>. Finally, one can also specify a model, in which there are no free variables and all doubtful variables are of interest: <strong>y ~ focus</strong>. When using the <strong>formula</strong> argument, the <strong>doubtful</strong> component of the right-hand side need not contain the <strong>focus</strong> variables.</p><p>If no other arguments are specified, <strong>eba()</strong> will conduct a ‘standard’ extreme bounds analysis based on Ordinary Least Squares (OLS) regressions with unadjusted standard errors. All hypothesis tests will be performed at the conventional 95 percent confidence level against the null hypothesis that the relevant parameter is equal to zero. Equal weights will be applied to results from each estimated model, and no maximum limit will be imposed on the variance inflation factor. Following established convention, <strong>eba()</strong> will include up to three doubtful variables in addition to the focus variable in each regression model.</p><p>The function <strong>eba()</strong>, however, also offers a great deal of flexibility for researchers who might be interested in conducting a different kind of extreme bounds analysis. Every aspect of EBA is fully customizable:</p><ul><li><strong>eba()</strong> can estimate any type of regression model (argument <strong>reg.fun</strong>), not just Ordinary Least Squares (OLS). Researchers can thus easily perform EBA using, for instance, logistic or probit regressions. Attention can, furthermore, be restricted to regressions in which the variance inflation factor on the examined coefficient does not exceed a set maximum (argument <strong>vif</strong>). Alternatively, users can request that <strong>eba()</strong> only use results from regression models that meet some other, user-specified condition (argument <strong>include.fun</strong>).</li><li>Regression models can be specified very flexibly (argument <strong>formula</strong>). They can contain interaction terms, squared or cubic terms to account for non-linear relationships, as well as the lags, natural logarithms or other functions of the included variables. The function automatically transforms the variables and creates the appropriate model matrices. These regression models can be of a variety of sizes, as the user can choose how many doubtful variables should be included in each specification (argument <strong>k</strong>). Most applications have included up to three doubtful variables per estimated model. Nevertheless, the researcher’s choice of <strong>k</strong> can be somewhat arbitrary in practice, and will generally have to strike a balance between estimating more model specifications and controlling for too many variables.</li><li>Users can specify sets of mutually exclusive variables that will never be included in the same regression model to alleviate concerns about regressor multicollinearity (argument <strong>exclusive</strong>). Specifying which doubtful variables cannot be included together can also be useful when several doubtful variables measure the same substantive concept.</li><li>All hypothesis tests can be performed at any requested confidence level (argument <strong>level</strong>). In addition, the user can specify the null hypothesis value for each regression coefficient (argument <strong>mu</strong>). <strong>eba()</strong> can thus check whether the estimated coefficients are robustly different from any numerical value, not just from zero.</li><li>If desired, weights can be applied to results from each estimated regression (argument <strong>weights</strong>). The weights can be based on the regression R², adjusted R², McFadden’s likelihood ratio index, or calculated by a user-provided function.</li><li>In conjunction with other <strong>R</strong> packages, <strong>eba()</strong> can apply various types of standard errors in its calculations (argument <strong>se.fun</strong>). It can, for instance, apply heteroskedasticity-robust, clustered, and Newey-West standard errors provided by the <strong>sandwich</strong> package, as well as panel-corrected standard errors from the <strong>pcse</strong> package. Additionally, users can also provide <strong>eba()</strong> with their own functions to calculate standard errors.</li><li>To reduce the time required to complete the analysis, <strong>eba()</strong> can estimate a random sample of any given size drawn from the full set of the regression models (argument <strong>draws</strong>). For Sala-i-Martin’s EBA, this procedure yields unbiased estimates of the quantities of interest that can give the researcher a good sense of the full results within a reasonable time frame. Note, however, that random sampling can lead to the overestimation of the lower extreme bound and to the underestimation of the upper extreme bound in Leamer’s EBA. Researchers should therefore be cautious in interpreting Leamer’s EBA results that are not estimated from the full universe of regression models.</li></ul><p>The function <strong>eba()</strong> returns an object of class <strong>“eba”</strong>, which can then be passed on to the <strong>print()</strong> method to obtain a text summary of EBA results, or to the <strong>hist()</strong> method to produce histograms that will provide a graphical illustration of the estimation results. The object contains a <strong>bounds</strong> data frame with the results of both Leamer’s and Sala-i-Martin’s extreme bounds analysis, as well as a <strong>coefficients</strong> data frame with various quantities of interest: the minimum, maximum, mean and median values of coefficient estimates, along with the individual CDF(0)’s for Sala-i-Martin’s generic EBA model.</p><p>In addition, the object stores the total number of doubtful variable combinations that include at least one focus variable (component <strong>ncomb</strong>), the number of regressions actually estimated in total (<strong>nreg</strong>) and by variable (<strong>nreg.variable</strong>), along with the number of coefficients used in the extreme bounds analysis (<strong>ncoef.variable</strong>). Importantly, the <strong>“eba”</strong>-class object also contains the estimation results from each regression model (component <strong>regressions</strong>). As a result, researchers can easily use the large number of regressions that EBA often produces in their own analyses, whether those be modifications of extreme bounds analysis or an entirely different statistical method.</p><h3>Text Summary: Method print()</h3><p>Once the function <strong>eba()</strong> has completed its calculations, the user can obtain a text summary of the estimation results by passing the <strong>“eba”</strong>-class object to the <strong>print()</strong> method. The summary contains information about the number of regressions that <strong>eba()</strong> has estimated, as well as about the distribution of regression coefficient estimates. Most importantly, it provides a comprehensive summary of the analysis results for both Leamer’s and Sala-i-Martin’s EBA. The user can adjust the number of decimal places to which all numerical figures in the output are rounded by changing the value of the <strong>digits</strong> argument.</p><p>At the top of the text output, the <strong>print()</strong> method reproduces the <strong>eba()</strong> function call, the confidence level, as well as the total number of variable combinations, the number of regressions that were actually estimated (in total, by variable, and as a proportion of the number of combinations) and the number of coefficients used in the EBA (by variable). The remainder of the output is divided into four parts, which I briefly summarize below:</p><ul><li><strong>Beta coefficients</strong>: This part contains the weighted mean of the estimated regression coefficients and of their standard errors. Individual regression models receive a weight specified by the <strong>eba()</strong> function’s argument <strong>weights</strong>. In addition, the <strong>print()</strong> method also reports the value of the lowest and highest regression coefficients across the estimated models, along with the corresponding standard errors.</li><li><strong>Distribution of beta coefficients:</strong> Here, the method reports the percentage of regression coefficients that are lower/greater than zero, along with the proportion that is statistically significantly different from zero at the specified confidence level. If a different value under the null hypothesis is specified, all regression coefficients are compared with <strong>mu</strong> rather than with zero.</li><li><strong>Leamer’s Extreme Bounds Analysis:</strong> Both the lower and upper extreme bounds, at the specified confidence levels, from Leamer’s extreme bounds analysis are reported. Based on these bounds, each variable is classified as either <strong>robust</strong> or <strong>fragile</strong>.</li><li><strong>Sala-i-Martin’s Extreme Bounds Analysis:</strong> Finally, the <strong>print()</strong> method reports results from Sala-i-Martin’s EBA. In particular, for both the normal and generic models, the text output prints out the value of the aggregate CDF(0) (or CDF(<strong>mu</strong>), if appropriate), along with its complement 1 — CDF(0).</li></ul><h3>Histograms: Method hist()</h3><p>In addition to providing text output with EBA results, the <strong>ExtremeBounds</strong> package can produce histograms that summarize the distribution of estimated regression coefficients graphically for each examined variable. These histograms can, furthermore, be superimposed with curves that depict the corresponding kernel density or a normally distributed approximation to the coefficient distribution. Such approximations can give the researcher a succinct summary of the shape of the coefficient distribution. As such, they provide a simple way of examining whether the estimated regression coefficients concentrate around a particular value or have, for instance, a multimodal distribution.</p><p>To produce EBA histograms, the user simply passes an <strong>“eba”</strong>-class object created by the main function <strong>eba()</strong> to the <strong>hist()</strong> method. The user can choose between histograms that represent frequencies or probability densities (argument <strong>freq</strong>). Unless the set of variables to be included is specified (argument <strong>variables</strong>), the method will produce histograms for all variables included in the extreme bounds analysis.</p><p>By default, the histograms include vertical lines that indicate the parameter value under the null hypothesis (argument <strong>mu.show</strong>), as well as a kernel density curve that relies on <strong>R</strong>’s standard <strong>density</strong> method (argument <strong>density.show</strong>). The kernel density curve provides a non-parametric estimate of the EBA coefficients’ probability density function. In addition, the <strong>hist()</strong> method for <strong>“eba”</strong> objects can overlay the histograms with a density curve for a normal distribution function that approximates the distribution of EBA coefficients (argument <strong>normal.show</strong>).</p><p>Many formatting options are available. Users can change the colors and widths of the vertical lines for null hypothesis values (arguments <strong>mu.col</strong> and <strong>mu.lwd</strong>), of the kernel density curves (<strong>density.col</strong> and <strong>density.lwd</strong>), and of the density curves for the normally distributed approximation (<strong>normal.col</strong> and <strong>normal.lwd</strong>). The user also has complete control over a variety of other visual properties of the histograms. These include the histograms’ title labels (argument <strong>main</strong>), the range of values on the horizontal axis (<strong>xlim</strong>), as well as the color of the histogram bars (<strong>col</strong>).</p><h3>Example: The Fuel Economy of Automobiles</h3><p>In this section, I demonstrate the capabilities of the <strong>ExtremeBounds</strong> package using an empirical example. In particular, I identify robust determinants of the fuel economy of selected automobiles using data from the data frame <strong>mtcars</strong>. This data frame is included in the <strong>datasets</strong> package, which is part the standard <strong>R</strong> distribution <strong>R</strong> and is therefore readily available to the beginning <strong>ExtremeBounds</strong> user.</p><p>The information in <strong>mtcars</strong> was extracted from the 1974 <em>Motor Trend</em> magazine, and comprises the fuel consumption and ten aspects of vehicle design and performance for a selection of 1973–1974 automobile models. The <strong>mtcars</strong> data set is particularly well-suited for a demonstration of extreme bounds analysis, as its small size allows me to highlight the <strong>ExtremeBounds</strong> package’s most important features without having to perform time-consuming estimations of a very large number of regressions.</p><p>The data frame <strong>mtcars</strong> contains 32 observations. Each observation is one particular model of automobile (e.g.,<strong> “Mazda RX4”</strong>, <strong>“Cadillac Fleetwood”</strong> or <strong>“Fiat X1–9”</strong>). For each model, the data frame contains information on its fuel economy, expressed as the vehicle’s miles per gallon (variable <strong>mpg</strong>), and about its engine — the number of cylinders (<strong>cyl</strong>) and carburetors (<strong>carb</strong>), its displacement in cubic inches (<strong>disp</strong>), its gross horsepower (<strong>hp</strong>), as well as whether it is a V- or a straight engine (<strong>vs</strong>). In addition, we are given information about each model’s rear axle ratio (<strong>drat</strong>), weight in thousands of pounds (<strong>wt</strong>), and quarter-mile time in seconds (<strong>qsec</strong>). The variable <strong>gear</strong> contains the number of forward gears, while <strong>am</strong> indicates whether the automobile has an automatic or manual transmission, with a value of 1 denoting a manual transmission.</p><p><strong>Naive EBA with All Combinations of Doubtful Variables</strong></p><p>First, I would like to get a basic sense of which determinants might be most robustly associated with the dependent variable <strong>mpg</strong> (miles per gallon). I therefore begin by conducting an EBA that estimates all possible combinations of doubtful variables across the ten automobile design and performance characteristics included in <strong>mtcars</strong>. Since I am interested in the robustness or fragility of all the doubtful variables, I regard all of them as focus.</p><p>From a statistical point of view, this type of EBA is somewhat naive, as it does not take into account the possibility of high multicollinearity among the included variables. Neither does it account for the possibility that some variables measure similar concepts. The number of cylinders (<strong>cyl</strong>) and the gross horsepower (<strong>hp</strong>) might, for example, both be seen as measures of the engine’s overall performance. Researchers interested in examining the fuel economy of automobiles would thus, in contrast to my naive EBA, be unlikely to include both explanatory variables in the same regression model.</p><p>An extreme bounds analysis with all combinations of doubtful variables might nevertheless yield some valuable insights. In particular, it provides a particularly strong test for a determinant’s robustness. As some researchers have suggested, such an EBA might indicate which variables should be treated as free, and therefore be included in all regression models in further EBA analyses.</p><p>I estimate the naive EBA by calling the <strong>eba()</strong> function:</p><p><strong>R&gt; naive.eba &lt;- eba(formula = mpg ~ cyl + carb + disp + hp + vs + drat + wt + qsec + gear + am, data = mtcars, k = 0:9)</strong></p><p>Alternatively, I can use character vectors to specify the dependent and doubtful variables using the <strong>y</strong> and <strong>doubtful</strong> arguments, respectively:</p><p><strong>R&gt; naive.eba &lt;- eba(data = mtcars, y = “mpg”, doubtful = c(“cyl”, “carb”, “disp”, “hp”, “vs”, “drat”, “wt”, “qsec”, “gear”, “am”), k = 0:9)</strong></p><p>Since the <strong>focus</strong> argument is not specified, all the <strong>doubtful</strong> variables will be treated as focus variables. The argument <strong>k = 0:9</strong> ensures that, on top of the focus variable, up to nine doubtful variables will be included in each regression model. As a result, regressions with all possible combinations of the ten doubtful variables will be estimated. The <strong>eba()</strong> function will return an object of class <strong>“eba”</strong> that will be stored in <strong>naive.eba</strong>.</p><p>Next, I ask <strong>ExtremeBounds</strong> to produce a set of histograms that summarize the EBA estimation results. To do so, I simply pass the <strong>naive.eba</strong> object to the <strong>hist()</strong> method:</p><p><strong>R&gt; hist(naive.eba)</strong></p><p>The resulting histograms are reproduced in <em>Figure 1</em>. The gray bins contain the Ordinary Least Squares (OLS) coefficients on each examined variable from all of the estimated regression models. Superimposed over each histogram is a thick blue curve that represents the corresponding kernel density, a non-parametric approximation of the shape of each regression coefficient’s distribution. The kernel density curves can be helpful in identifying whether these distributions have, for instance, multiple modes. There is also a red vertical line at zero, the default coefficient value under the null hypothesis.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/849/1*nwi8D-U4cf3vXF6JgjJWdg.png" /><figcaption>Figure 1: Histograms that summarize the estimation results of the naive EBA. The magnitudes of regression coefficients are on the horizontal axis. The vertical axis indicates the corresponding probability density.</figcaption></figure><p>A visual inspection of the histograms allows me to get a quick overview of the EBA estimation results. If most of the histogram bins’ area lies to the right of zero, a majority of the regression coefficient estimates on the corresponding variables are positive. A positive coefficient indicates that, holding all else equal, a higher value of the examined variable is associated with more miles per gallon, as given by the dependent variable (<strong>mpg</strong>). The results of the naive EBA suggests that straight engines (<strong>vs</strong>), a greater rear axle ratio (<strong>drat</strong>), a slower quarter-mile time (<strong>qsec</strong>), a greater number of forward gears (<strong>gear</strong>) and a manual transmission (<strong>am</strong>) are associated with greater fuel economy.</p><p>Conversely, if most of the bins’ area lies to the left of zero, greater values of the corresponding variable are associated with lower miles per gallon, <em>ceteris paribus</em>, in most estimated regressions. Naive EBA estimation results indicate that engines with more cylinders (<strong>cyl</strong>), curburetors (<strong>carb</strong>) and with greater gross horsepower (<strong>hp</strong>) achieve worse fuel economy. The vehicle’s greater weight (<strong>wt</strong>) is consistently associated with greater fuel consumption. In fact, <strong>wt</strong> is the only variable for which all of the estimated regression coefficients have the same (in this case, negative) sign.</p><p>Engine displacement (<strong>disp</strong>) appears to be an interesting case, as the distribution of the regression coefficients appears to be bimodal. Some are negative, while others are positive. The bimodal nature of the distribution can be easily seen from the two different peaks of the histogram bins, as well as from the double hump of the kernel density curve.</p><p><strong>A More Sophisticated EBA</strong></p><p>Having inspected the results of my naive EBA, I can now use the <strong>ExtremeBounds</strong> package’s capabilities to make my analysis more sophisticated. In particular, I make the following changes to the <strong>eba()</strong> function call:</p><ul><li>Results from the naive EBA have indicated that the regression coefficients on the vehicle’s weight (<strong>wt</strong>) are negative, regardless of the model specification. For this reason, I treat <strong>wt</strong> as a free variable to be included in all regression models.</li><li>Some of the doubtful variables measure similar concepts, and were therefore inappropriately included together in regression models by the naive EBA. To prevent conceptual overlap, I use the <strong>exclusive</strong> parameter to specify two sets of mutually exclusive variables: One set consists of variables that might be construed as measuring the performance of the engine: the number of cylinders (<strong>cyl</strong>), the number of carburetors (<strong>carb</strong>), engine displacement (<strong>disp</strong>) and the gross horsepower (<strong>hp</strong>). The other set consists of the two doubtful variables that have to do with the car’s transmission: the <strong>am</strong> indicator of an automatic vs. manual transmission, and the number of forward gears (<strong>gear</strong>).</li><li>I am only interested in estimation results for the four variables that measure engine performance: <strong>cyl</strong>, <strong>carb</strong>, <strong>disp</strong> and <strong>hp</strong>. I therefore specify them as the focus variables.</li><li>Rather than estimating all possible combinations of the doubtful variables as I did in the naive EBA, I only add combinations of up to three doubtful variables to the focus variable in each specification. The value of the <strong>k</strong> argument will thus remain at its default value of <strong>0:3</strong>.</li><li>To eliminate the influence of coefficient estimates from model specifications that suffer from high multicollinearity, I specify a maximum acceptable variance inflation factor by setting <strong>vif = 7</strong>.</li><li>I use heteroskedasticity-robust standard errors, as calculated by the <strong>sandwich</strong> package. To be able to do this, I define the <strong>se.robust</strong> function (below) that calculates the standard errors, and pass it to the <strong>eba()</strong> function:</li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/551/1*6_x3ISGN-gzjRsRBHmlZgA.png" /></figure><ul><li>Finally, I give more weight to estimation results from regression models that provide a better fit to the data. More specifically, I set the argument <strong>weights</strong> to <strong>“lri”</strong>, and thus weight each model’s results by its likelihood ratio index.</li></ul><p>I execute the following <strong>R</strong> code to estimate this more sophisticated extreme bounds analysis:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/827/1*TFpABTH3tYHlK3uhPqL46A.png" /></figure><p>I could, of course, achieve the same result by passing the sets of variables via the <strong>y</strong>, <strong>free</strong>, <strong>doubtful</strong> and <strong>focus</strong> arguments, as shown below. The <strong>exclusive</strong> argument can accept a list of character vectors in lieu of a multiple-part <strong>“Formula”</strong> object.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/847/1*Cbho8s7euRT9-Zh1MAqVAg.png" /></figure><p>Again, I produce a set of histograms that will allow me to get an initial sense of the results of my analysis. This time, I include the <strong>hist()</strong> method’s <strong>variables</strong> argument to request histograms only for the four focus variables that I am interested in. Additionally, I use the <strong>main</strong> argument to make each histogram’s main title more descriptive and the <strong>normal.show</strong> argument to request that <strong>hist()</strong> superimpose a density curve with a normally distributed approximation to the coefficient distribution.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/841/1*7YZABJLt3yXAmbXzpjs4WA.png" /></figure><p>As the histograms in<em> Figure 2</em> show, the more sophisticated EBA leads to more clear-cut predictions about the signs of regression coefficients than the naive EBA estimated earlier. The coefficients on all four focus variables are consistently negative. This result suggests that, across a wide variety of reasonably well-specified regression models, a greater number of cylinders and carburetors, as well as greater engine displacement and gross horsepower, are associated with worse fuel economy (i.e., with fewer miles per gallon).</p><p>It is, moreover, evident that the blue kernel density curve and the green normally distributed approximation are quite different from each other. This lack of alignment suggests that regression coefficients are not normally distributed across model specifications.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/839/1*rgC-jRj0m6-aY2n4GNrJAw.png" /><figcaption>Figure 2: Histograms that summarize the estimation results of the sophisticated EBA. The magnitudes of regression coefficients are on the horizontal axis. The vertical axis indicates the corresponding probability density.</figcaption></figure><p>In addition to histograms, <strong>ExtremeBounds</strong> allows users to examine EBA results through the text output produced by the <strong>print()</strong> method. This method produces a wealth of detailed information about the estimation results from both Leamer’s and Sala-i-Martin’s extreme bounds analysis. In the interest of clarity, I reproduce only the portions of <strong>print()</strong> output that are most relevant to my empirical example. <strong>ExtremeBounds</strong> users can type <strong>?print.eba</strong> in the <strong>R </strong>console to obtain a complete description of the text output.</p><p>I obtain a text summary of my analysis results by passing the <strong>“eba”</strong>-class object to the <strong>print()</strong> method:</p><p><strong>R&gt; print(sophisticated.eba)</strong></p><p>At the top of the <strong>print()</strong> method’s text output, we find information about the number of specifications that were estimated. In total, there are 148 possible combinations of the examined doubtful variables that contain at least one focus variable. Since the parameter <strong>draws</strong> is not specified, no random sampling of estimated models occurs. As a result, <strong>eba()</strong> estimates all of the available combinations.</p><p>The free variable <strong>wt</strong> occurs, of course, in all 148 regression models. The focus variables are included in fewer specifications since each of them does not appear in some doubtful variable combinations. The four focus variables have, furthermore, been specified as mutually exclusive (in the <strong>eba()</strong> function’s argument <strong>exclusive</strong>) and cannot therefore be included together in the same regression model. The <strong>print()</strong> method reports that the focus variables <strong>cyl</strong>, <strong>carb</strong>, <strong>disp</strong> and <strong>hp</strong> appear in 37 specifications each. The output also indicates that only 26 and 14 coefficient estimates (rather than all 37) were used in the extreme bounds analysis for the variables <strong>cyl</strong> and <strong>disp</strong>, respectively. The reduction in the number of coefficients used occurs because the variance inflation factors on some <strong>cyl</strong> and <strong>disp</strong> coefficients exceed the specified maximum of 7.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/813/1*NmBWuOF-2Yk2-E5GAWXxZg.png" /></figure><p>Next, the <strong>print()</strong> method reports the weighted means of coefficient and standard error estimates for the free and focus variables across the estimated regression models. The weights are specified in the <strong>eba()</strong> function’s <strong>weights</strong> argument. In the sophisticated analysis I ran, I weight regression models by the likelihood ratio index.</p><p>The table reproduced below shows that, on average, a vehicle weight (<strong>wt</strong>) that is greater by a thousand pounds is associated with 3.623 fewer miles per gallon (<strong>mpg</strong>). An additional cylinder (<strong>cyl</strong>) or carburetor (<strong>carb</strong>) yields a decrease of 1.370 and 0.822 miles per gallon, respectively. One cubic inch of additional engine displacement (<strong>disp</strong>) is associated with 0.016 fewer miles per gallon. Finally, a gallon of fuel yields 0.027 fewer miles with each unit of gross horsepower (<strong>hp</strong>). Relative to the size of the coefficients, the weighted standard errors are relatively small.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/579/1*V34EV1J9OJRNC9brdqUZjg.png" /></figure><p>The text output from <strong>print()</strong> proceeds to summarize the distribution of coefficient estimates. It reports the proportions, expressed as percentages, of estimated regression coefficients that are lower or greater than zero. In our example, the coefficients on <strong>wt</strong>, <strong>cyl</strong>, <strong>carb</strong>, <strong>disp</strong> and <strong>hp</strong> are all negative, while the coefficients on the intercept term in the linear regression are always positive. These statistics are, of course, consistent with the information displayed in the histograms in <em>Figure 2</em>.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/549/1*hmMq0x3yp7m11MBVZvcivA.png" /></figure><p>Even though all the free and focus variables’ coefficients are negative, some of the point estimates may not be distinguishable from zero in a statistically significant way. The text output also includes the percentages of regression coefficients that are <em>both</em> statistically significant and lower/greater than zero. We find that only in the case of the free variable <strong>wt</strong> are all the coefficients statistically significant. A very large majority of coefficient estimates are significant for the <strong>cyl</strong> and <strong>hp</strong> variables (92.3 and 81.1 percent, respectively). By contrast, only about 60 percent of coefficients on <strong>carb</strong> and <strong>disp</strong> are statistically significant.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/748/1*_Dl8EI9FL4Z7kYC7xxoJ5g.png" /></figure><p>The <strong>print()</strong> method then goes on to summarize results from Leamer’s extreme bounds analysis. It produces a table that includes the lower and upper extreme bounds of regression coefficient estimates, and — based on these bounds — classifies determinants as robust or fragile. The only variable that is found to be robust using Leamer’s EBA is the free variable <strong>wt</strong>. Since the upper and lower extreme bounds of all the focus variables have opposite signs, they are declared to be fragile.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/865/1*hmJldE-LYybTnV9lOy_jww.png" /></figure><p>Finally, the text output includes results from Sala-i-Martin’s extreme bounds analysis. The histograms in <em>Figure 2</em> suggest that the normally distributed approximation of the regression coefficients’ distribution does not provide a good fit to the data. For this reason, I focus on EBA results from the generic model, which does does not assume any particular distribution of coefficient estimates across different specifications.</p><p>As the table presented below indicates, results from Sala-i-Martin’s EBA suggest very little fragility of the coefficient estimates. For variables <strong>wt</strong>, <strong>cyl</strong> and <strong>hp</strong>, more than 99 percent of the cumulative distribution of regression coefficients lies below zero. The same can be said of more than 95 percent of the cumulative distributions for variables <strong>carb</strong> and <strong>disp</strong>. According to results from Sala-i-Martin’s EBA, all of the free and focus variables appear to be robustly (and negatively) associated with the automobiles’ miles per gallon (<strong>mpg</strong>). In contrast to Leamer’s EBA in which a single insignificant coefficient implies fragility, the less stringent Sala-i-Martin’s EBA classifies more variables as robust determinants of fuel economy.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/627/1*51zDPtpuCs-fztaAzjvqSA.png" /></figure><p>All in all, the extreme bounds analysis in this empirical example suggests that the examined automobiles’ weight and engine performance are robustly associated with the vehicles’ fuel economy. In conducting the analysis, I have demonstrated some of the most important features of the <strong>ExtremeBounds</strong> package. Specifically, I have shown how researchers can estimate Leamer’s and Sala-i-Martin’s EBA using the fully customizable <strong>eba()</strong> function. The estimation results can then be visually inspected with the help of the <strong>hist()</strong> method that produces histograms of each examined variable’s coefficient estimates. Finally, the <strong>print()</strong> method provides users with text output that contains a detailed summary of EBA estimation results.</p><p>In this two-part article, I have introduced the ExtremeBounds package for the R statistical programming language. The package allows researchers to perform extreme bounds analysis (EBA), a sensitivity test that calculates how robustly a regression model’s dependent variable is associated with a variety of possible determinants. <a href="https://medium.com/@MarekHlavac/package-extremebounds-for-extreme-bounds-analysis-in-r-part-1-introduction-and-theory-a79409e2bd44">Part 1</a> introduced some of the theory behind extreme bounds analysis.</p><p><strong>ExtremeBounds</strong> represents a significant improvement over existing software implementations of extreme bounds analysis, as it supports not only Leamer’s version of extreme bounds analysis, but also Sala-i-Martin’s EBA. Furthermore, the package allows users to customize every aspect of the analysis: the type of regression model, its size and functional form, as well as the standard errors and weights.</p><p>Here, in Part 2, I have showcased many of these customizable features through an empirical example that focused on the determinants of selected automobiles’ fuel economy. Along the way, I have also demonstrated the package’s ability to produce histograms of estimated regression coefficients via the <strong>hist()</strong> method, and to print out a detailed text summary of the EBA estimation results through the <strong>print()</strong> method.</p><p><strong>About the author: </strong>Marek Hlavac teaches economics at <a href="https://www.uwcad.it/">UWC Adriatic</a>, an international secondary school in Duino (Trieste), Italy. In addition, he is a research fellow at the <a href="http://celsi.sk/en/">Central European Labour Studies Institute (CELSI)</a> in Bratislava, Slovakia. He holds a Bachelor’s degree in Economics from Princeton University, a Master’s degree in Public Policy from Georgetown University, and a Ph.D. in Political Economy and Government from Harvard University. You can find his personal website <a href="https://sites.google.com/site/marekhlavac/">here</a>.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=fd452536b996" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Package “ExtremeBounds” for Extreme Bounds Analysis in R — Part 1: Introduction and Theory]]></title>
            <link>https://medium.com/@MarekHlavac/package-extremebounds-for-extreme-bounds-analysis-in-r-part-1-introduction-and-theory-a79409e2bd44?source=rss-bcf2a64a4cae------2</link>
            <guid isPermaLink="false">https://medium.com/p/a79409e2bd44</guid>
            <category><![CDATA[data-science]]></category>
            <category><![CDATA[economics]]></category>
            <category><![CDATA[econometrics]]></category>
            <category><![CDATA[r]]></category>
            <category><![CDATA[statistics]]></category>
            <dc:creator><![CDATA[Marek Hlavac]]></dc:creator>
            <pubDate>Wed, 03 Jan 2018 07:42:21 GMT</pubDate>
            <atom:updated>2018-01-03T07:48:43.294Z</atom:updated>
            <content:encoded><![CDATA[<p><em>The text that follows is an abridged and simplified version of an article, published in the </em><a href="https://www.jstatsoft.org/index">Journal of Statistical Software</a><em>, that describes my </em><strong><em>ExtremeBounds</em></strong><em> R package. Part 1, below, introduces the package and explains some econometric theory behind extreme bounds analysis. </em><a href="https://medium.com/@MarekHlavac/package-extremebounds-for-extreme-bounds-analysis-in-r-part-2-features-and-example-fd452536b996"><em>Part 2</em></a><em> presents specific features of the </em><strong><em>ExtremeBounds</em></strong><em> package, and illustrates their use with an example. For a more complete treatment with full academic citations and references, please refer to the </em><a href="https://cran.r-project.org/web/packages/ExtremeBounds/vignettes/ExtremeBounds.pdf"><em>full article</em></a><em>.</em></p><p>If you use the <strong>ExtremeBounds</strong> package in your research, please do not forget to cite it:</p><blockquote>Hlavac, Marek (2016). ExtremeBounds: Extreme Bounds Analysis in R. Journal of Statistical Software, 72(9), 1–22. doi:10.18637/jss.v072.i09.</blockquote><p><strong>Abstract: </strong>This article introduces the <strong>R</strong> package <strong>ExtremeBounds</strong> to perform extreme bounds analysis (EBA), a sensitivity test that examines how robustly the dependent variable of a regression model is related to a variety of possible determinants. <strong>ExtremeBounds</strong> supports Leamer’s EBA that focuses on the upper and lower extreme bounds of regression coefficients, as well as Sala-i-Martin’s EBA which considers their entire distribution. In contrast to existing alternatives, it can estimate models of a variety of user-defined sizes, use regression models other than Ordinary Least Squares, incorporate non-linearities in the model specification, and apply custom weights and standard errors. To alleviate concerns about the multicollinearity and conceptual overlap of examined variables, <strong>ExtremeBounds</strong> allows users to specify sets of mutually exclusive variables, and can restrict the analysis to coefficients from regression models that yield a variance inflation factor within a pre-specified limit.</p><h3>Introduction</h3><p>The <strong>R</strong> package <strong>ExtremeBounds</strong> performs extreme bounds analysis (EBA), a sensitivity test that examines how robustly the dependent variable of a regression model is associated with a variety of possible determinants. EBA sifts through a large number of model specifications to answer the following questions:</p><ul><li>Which determinants are robustly associated with the dependent variable across a large number of possible regression models?</li><li>Is a particular determinant robustly associated with the dependent variable?</li></ul><p>Extreme bounds analysis is useful for testing whether minor changes in the list of examined variables can fundamentally alter the conclusions of empirical research studies. Researchers can therefore use EBA to demonstrate the “inferential sturdiness” of their results — in other words, their robustness to the inclusion or exclusion of a variety of plausible explanatory variables.</p><p>In addition, extreme bounds analysis can help researchers address model uncertainty in regression analysis. Even in cases where the correct functional form (e.g., linear, log-linear or quadratic) is known, it may not be obvious which variables belong in the “true” regression. To aid with variable selection, EBA can identify explanatory variables that are most robustly associated with the outcome variable.</p><p>Extreme bounds analysis is, of course, not the only method that can be useful in dealing with model uncertainty and regressor selection. Alternative approaches include a variety of Bayesian model averaging methods, the Bayesian Averaging of Classical Estimates or random forests. Nevertheless, EBA may be appealing to researchers because it is easy to grasp intuitively, relatively simple to estimate, and yields results that are easy to interpret within the frequentist inference framework.</p><p>Extreme bounds analysis has been used to examine a plethora of questions of interest to social scientists. Economists have used it to examine the determinants of long-term economic growth, regional growth rates, foreign direct investment, as well as investment in research and development. Political scientists have analyzed democratization, political repression and lending decisions by the International Monetary Fund. Other examples of EBA in the social scientific literature include an examination of the relationship between wage inequality and crime rates, of the effects of concealed weapons laws in the United States, and even of the determinants of Olympic medal counts.</p><p>The <strong>R</strong> package <strong>ExtremeBounds</strong> supports a demanding version of EBA, proposed by Edward Leamer, that focuses on the upper and lower extreme bounds of regression estimates, as well as a more flexible version by Xavier Sala-i-Martin. Sala-i-Martin’s EBA considers the entire distribution of regression coefficients — i.e., coefficients from all estimated regression models, not just those that yield the upper and lower extreme bounds. For Sala-i-Martin’s version of extreme bounds analysis, <strong>ExtremeBounds</strong> estimates the normal model in which regression coefficients are assumed to be normally distributed across models, as well as the generic model which makes no such assumption.</p><p>The <strong>ExtremeBounds</strong> package can be installed free of charge from the <strong>CRAN</strong> in the usual way:</p><p><strong>R&gt; install.packages(“ExtremeBounds”)</strong></p><p>The package provides users with a large number of important features that distinguish it from existing alternatives for EBA estimation. In particular, <strong>ExtremeBounds</strong> can estimate models of a variety of user-defined sizes, use regression models other than Ordinary Least Squares and incorporate non-linearities in the model specification. In addition, it can apply custom weights and standard errors in order to give regression models with a better fit more weight in the analysis.</p><p>To alleviate concerns about the multicollinearity or conceptual overlap of examined variables, <strong>ExtremeBounds</strong> allows users to specify sets of mutually exclusive variables. It can also restrict the analysis to coefficients from regression models that yield a variance inflation factor within a given maximum limit. The variance inflation factor is a rule-of-thumb indicator of multicollinearity in Ordinary Least Squares regression models. More specifically, it quantifies how much the variance of estimated regression coefficients is increased due to regressor collinearity.</p><h3>Extreme Bounds Analysis</h3><p>The basic idea of extreme bounds analysis is quite simple. We are interested in finding out which variables from the set <strong>X</strong> are robustly associated with the dependent variable <em>y</em>. To do so, we run a large number of regression models. Each has <em>y</em> as the dependent variable and includes a set of standard explanatory variables <strong>F</strong> that are included in each regression model. In addition, each model includes a different subset <strong>D</strong> of the variables in <strong>X</strong>. Following the convention in the literature, we will refer to <strong>F</strong> as the free variables and to <strong>X</strong> as the doubtful variables. Some subset of the doubtful variables <strong>X</strong> might be so-called focus variables that are of particular interest to the researcher. The doubtful variables whose regression coefficients retain their statistical significance in a large enough proportion of estimated models are declared to be robust, whereas those that do not are labelled fragile.</p><p>More formally, to find out whether a focus variable <em>v</em> in <strong>X</strong> is robustly correlated with the dependent variable <em>y</em>, we estimate a set of regression models of the following form:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/495/1*YOfdVHgz6F2YUaEQWe_5Qw.png" /></figure><p>where <em>j</em> indexes regression models, <strong>F</strong> is the full set of free variables that will be included in every regression model, <strong>D</strong><em>j</em> is a vector of <em>k</em> variables taken from the set <strong>X</strong> of doubtful variables, and ε is the error term. While <strong>D</strong><em>j</em> has conventionally been limited to no more than three doubtful variables per model, the particular choice of <em>k</em>, the number of doubtful variables to be included in each combination, is up to the researcher.</p><p>The above regression is estimated for each of the <em>M</em> possible combinations of <strong>D</strong><em>j</em> ⊂ <strong>X</strong>. The estimated regression coefficients on the focus variable <em>v</em>, along with the corresponding standard errors, are collected and stored for use in later calculations. In the original formulation of extreme bounds analysis, the regressions were estimated by Ordinary Least Squares (OLS). In recent research, however, other types of regression models have also been used, such as ordered probit models or logistic models.</p><p><strong>Leamer’s EBA</strong></p><p>In order to determine whether a determinant is robust or fragile, Leamer’s extreme bounds analysis focuses only on the extreme bounds of the regression coefficients. For any focus variable <em>v</em>, the lower and upper extreme bounds are defined as the minimum and maximum values of</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/129/1*-EsnlOJCmozW8T0JxHm-iw.png" /></figure><p>across the <em>M</em> estimated regression models, where <em>τ</em> is the critical value for the requested confidence level. For the conventional 95-percent confidence level, <em>τ</em> will thus be equal to approximately 1.96. If the upper and lower extreme bounds have the same sign, the focus variable <em>v</em> is said to be robust. Conversely, if the bounds have opposite signs, the variable is declared fragile.</p><p>The interval between the lower and upper extreme bound represents the set of values that are not statistically significantly distinguishable from the coefficient estimate. In other words, a simple t-test would fail to reject the null hypothesis that the true parameter equals any value between the extreme bounds. Intuitively, Leamer’s version of extreme bounds analysis scans a large number of model specifications for the lowest and highest value that the parameter could plausibly take at the requested confidence level. It then labels variables robust and fragile based on whether these extreme bounds have the same or opposite signs, respectively.</p><p>Leamer’s EBA relies on a very demanding criterion for robustness, since the results from a single regression model are enough to classify a determinant as fragile. In other words, a focus variable will be declared fragile even if the extreme bounds have the same sign in all estimated models except one. Accordingly, Xavier Sala-i-Martin notes that <em>“if the distribution of [regression coefficients] has some positive and some negative support, then one is bound to find one regression for which the estimated coefficient changes signs if enough regressions are run.</em>” It should come as no surprise that studies that have employed Leamer’s EBA to test the robustness of determinants have generally concluded that most, if not all, examined variables are fragile.</p><p><strong>Sala-i-Martin’s EBA</strong></p><p>In response to the perceived stringency of Leamer’s EBA, Sala-i-Martin proposes an alternative method for extreme bounds analysis that focuses on the entire distribution of regression coefficients, not just on its extreme bounds. Instead of applying a binary label of robust or fragile, he assigns some level of confidence to the robustness of each of the variables.</p><p>In particular, his approach considers the value of CDF(0), the fraction of the variable’s cumulative distribution that lies on each side of zero. To motivate his approach, he points out that <em>“if 95 percent of the density function for the [coeffiecient] estimates lies to the right of zero and only 52 percent of the density function […] lies to the right of zero, one will probably think of variable 1 as being more likely to be correlated with [the dependent variable] than variable 2.’’ </em>In short, Sala-i-Martin’s EBA considers a variable more robust if a greater proportion of its coefficient estimates lies on the same side of zero.</p><p>Although the coefficients in each individual model have an asymptotic normal distribution, the coefficient estimates obtained from different regression models might be scattered in less predictable ways and may not follow any particular distribution. For this reason, Sala-i-Martin presents two variants of his extreme bounds analysis — a normal model, in which the estimated regression coefficients are assumed to follow a normal distribution across the estimated models, as well as a generic model, which does not assume any particular distribution of regression coefficients.</p><p>To estimate the normal model, Sala-i-Martin first calculates the weighted mean of the regression coefficients and of the variances:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/272/1*6fXQekkf_yo-Ibc9tfQQwQ.png" /></figure><p>where <em>w</em> represents weights that are applied to results from each estimated regression model. Sala-i-Martin notes that applying weights enables the researcher to <em>“give more weight to regressions or models that are more likely to be the true model,”</em> assuming that <em>“the fit of model j is an indication of its probability of being the true model.”</em> Once the weighted means of coefficients and standard errors are known, Sala-i-Martin calculates CDF(0) — i.e., the cumulative density function evaluated at zero — based on the assumed normal distribution of regression coefficients such that</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/237/1*X_DEBQaAogAZx5YdaLbeKA.png" /></figure><p>In the generic model, Sala-i-Martin estimates the cumulative density function from each regression model separately, and pools them into an aggregate CDF(0) that then serves as a measure of the doubtful variable’s robustness. First, he uses the sampling distribution of the regression coefficient to obtain an individual CDF(0) for each estimated regression model. He then calculates the aggregate CDF(0) as the weighted average of all the individual CDF(0)’s:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/435/1*pDb_hJwhxAOnPg3iwrjnLw.png" /></figure><p>In both the normal and the generic model, Sala-i-Martin applies weights that are proportional to the integrated likelihood to give greater weight to models that provide a better fit:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/203/1*_HnouNNXkf-N5dHICHYcVQ.png" /></figure><p>In principle, of course, the weights could be based on any other measure of the goodness of fit. Alternative examples used in existing research literature include McFadden’s likelihood ratio index, or applying equal weights to each regression model.</p><p><a href="https://medium.com/@MarekHlavac/package-extremebounds-for-extreme-bounds-analysis-in-r-part-2-features-and-example-fd452536b996"><em>Continued in Part 2</em></a><em>, which presents specific features of the </em><strong><em>ExtremeBounds </em></strong><em>package, and illustrates their use with an example.</em></p><p><strong>About the author: </strong>Marek Hlavac teaches economics at <a href="https://www.uwcad.it/">UWC Adriatic</a>, an international secondary school in Duino (Trieste), Italy. In addition, he is a research fellow at the <a href="http://celsi.sk/en/">Central European Labour Studies Institute (CELSI)</a> in Bratislava, Slovakia. He holds a Bachelor’s degree in Economics from Princeton University, a Master’s degree in Public Policy from Georgetown University, and a Ph.D. in Political Economy and Government from Harvard University. You can find his personal website <a href="https://sites.google.com/site/marekhlavac/">here</a>.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=a79409e2bd44" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Package “oaxaca” for Blinder-Oaxaca Decomposition in R — Part 2: Features and Example]]></title>
            <link>https://medium.com/@MarekHlavac/package-oaxaca-for-blinder-oaxaca-decomposition-in-r-part-2-features-and-example-12222e9a886d?source=rss-bcf2a64a4cae------2</link>
            <guid isPermaLink="false">https://medium.com/p/12222e9a886d</guid>
            <category><![CDATA[labor-market]]></category>
            <category><![CDATA[r]]></category>
            <category><![CDATA[discrimination]]></category>
            <category><![CDATA[data-science]]></category>
            <category><![CDATA[economics]]></category>
            <dc:creator><![CDATA[Marek Hlavac]]></dc:creator>
            <pubDate>Wed, 03 Jan 2018 07:34:55 GMT</pubDate>
            <atom:updated>2018-01-03T07:44:28.885Z</atom:updated>
            <content:encoded><![CDATA[<p><em>The text that follows is an abridged and simplified version of the documentation vignette for my </em><strong><em>oaxaca</em></strong><em> R package. </em><a href="https://medium.com/@MarekHlavac/package-oaxaca-for-blinder-oaxaca-decomposition-in-r-part-1-introduction-and-theory-b8dafb085a31"><em>Part 1</em></a><em> introduced the package and explained some econometric theory behind the Blinder-Oaxaca decomposition. Part 2, below, presents specific features of the </em><strong><em>oaxaca</em></strong><em> package, and illustrates their use with a real-world example. For a more complete treatment with full academic citations and references, please refer to the </em><a href="https://cran.r-project.org/web/packages/oaxaca/vignettes/oaxaca.pdf"><em>full article</em></a><em>.</em></p><p>If you use the oaxaca package in your research, please do not forget to cite it:</p><blockquote>Hlavac, Marek. (2018). oaxaca: Blinder-Oaxaca Decomposition in R. R package version 0.1.4. <a href="https://cran.r-project.org/package=oaxaca">https://CRAN.R-project.org/package=oaxaca</a></blockquote><p>The <strong>oaxaca</strong> package consists of the main function <strong>oaxaca()</strong>, which performs the Blinder-Oaxaca decompositions, as well as of a related <strong>plot()</strong> method that produces a bar graph visualization of the decomposition results. In this section, I offer a brief overview of these functions’ capabilities. A more detailed description of the arguments and output of both functions can be obtained by typing <strong>?oaxaca</strong> or <strong>?plot.oaxaca</strong> into the <strong>R</strong> console.</p><h3>Decomposition Estimation: Main Function <em>oaxaca()</em></h3><p>The main function <strong>oaxaca()</strong> performs both the threefold and the twofold variants of the Blinder-Oaxaca decomposition using observations from the data frame provided in the <strong>data</strong> argument. The linear regression model for the Blinder-Oaxaca decomposition is specified through the <strong>formula</strong> argument. Users can pass on a multiple-part formula that specifies the dependent variable (<strong>y</strong>), the explanatory variables (<strong>x1</strong>, <strong>x2</strong>, <strong>x3</strong>, etc.), as well as an indicator variable (<strong>z</strong>) that indicates whether an observation belongs to Group A (when <strong>z </strong>equals FALSE or 0) or Group B (when it equals TRUE or 1). These variables, along with the functional form of the model, are passed on to the <strong>formula</strong> argument in an object of class <strong>“Formula”</strong> from the <strong>Formula</strong> package by Achim Zeileis and Yves Croissant.</p><p>Typically, the model formula takes the following form:</p><p><strong>y ~ x1 + x2 + x3 + … | z</strong></p><p>If the regression model contains dummies that represent a categorical variable (<strong>d1</strong>, <strong>d2</strong>, <strong>d3</strong>, etc.), these can be specified by adding another part to the formula:</p><p><strong>y ~ x1 + x2 + x3 + … | z | d1 + d2 + d3 + …</strong></p><p>When categorical variable dummies are specified, the <strong>oaxaca()</strong> function will automatically adjust estimates to be invariant with respect to the user’s choice of the omitted baseline category.</p><p>If the user does not include any other arguments, <strong>oaxaca()</strong> will estimate the Blinder-Oaxaca decompositions — both threefold and twofold — based on Ordinary Least Squares regressions (estimated via the standard <strong>lm() </strong>function), and will calculate standard errors based on 100 bootstrapping replicates. By default, <strong>oaxaca()</strong> estimates the twofold decomposition with Group A coefficients, Group B coefficients, their equally weighted average, a weighted average that reflects the number of observations in Groups A and B, as well with pooled coefficients — both including and excluding the group indicator variable — as the set of reference coefficients.</p><p>These defaults can, however, easily be changed. Users can use the argument <strong>group.weights</strong> to specify additional relative weights of Group A and Group B coefficients in the estimation of the twofold decomposition. They can also choose, via the <strong>R</strong> argument, how many bootstrapping resamples should be drawn to calculate the standard errors. Last but not least, users can use a different regression function (argument <strong>reg.fun</strong>) to estimate the regression coefficients used in the decompositions. Note that, if a non-linear function such as <strong>glm()</strong> is chosen, the decomposition will be based on the linear systematic component — usually associated with the estimation of the corresponding latent variable — of the regression method.</p><p>The function <strong>oaxaca()</strong> returns an object of class <strong>“oaxaca”</strong>, which can then be passed on to the <strong>plot()</strong> method to obtain a bar graph visualization of the Blinder-Oaxaca decomposition results. The object contains lists named <strong>threefold</strong> and <strong>twofold</strong> which contain the results of the threefold and twofold decompositions, respectively. In addition, the object stores the regression coefficients used in the decomposition (component <strong>beta</strong>), the number of observations in each group that were used in the analysis (<strong>n</strong>), the number of bootstrapping replicates (<strong>R</strong>), the regression objects generated during the analysis (<strong>reg</strong>), as well as the mean values of both the dependent variable (<strong>y</strong>) and the explanatory variables (<strong>x</strong>).</p><h3>Visualization: Method <strong>plot()</strong></h3><p>The <strong>oaxaca</strong> package can produce easily customizable bar charts that visually summarize the results of its Blinder-Oaxaca decompositions. All bar charts are generated using the <strong>ggplot2</strong> package by Hadley Wickham. To visualize the decomposition results, the user simply passes an “<strong>oaxaca</strong>”-class object created by the main function <strong>oaxaca()</strong> to the <strong>plot()</strong> method.</p><p>Users can choose which of the estimated decompositions to visualize. The <strong>decomposition</strong> argument determines whether a threefold or a twofold Blinder-Oaxaca decomposition will be shown, while the <strong>type</strong> argument specifies whether the bar graph will contain an overall decomposition or a detailed, variable-by-variable one. If the detailed decomposition type is selected, <strong>component.left</strong> determines whether decomposition components or variable names will be aligned along the left side of the graph. The argument <strong>weight</strong> allows the user to select which of the twofold decompositions should be shown, and the <strong>unexplained.split</strong> argument determines whether the unexplained components ought to be split into the two discrimination subcomponents (“unexplained A” and “unexplained B”).</p><p>Users can, furthermore, choose which of the variables and decomposition components will be shown (arguments <strong>variables</strong> and <strong>components</strong>), as well as their labels (<strong>variable.labels</strong> and <strong>component.labels</strong>). Standard error bars that indicate confidence intervals can be toggled by the <strong>ci</strong> argument, and the confidence level adjusted by <strong>ci.level</strong>. Several formatting options are available. The bar graph’s title can be set using the <strong>title</strong> argument, and axes can be labeled by <strong>xlab</strong> and <strong>ylab</strong>. Finally, users can change the colors of the bars by specifying the <strong>bar.color</strong> argument.</p><h3>Example: Wages of Native and Foreign-Born Workers</h3><p>In this section, I use an empirical example to demonstrate the capabilities of the <strong>oaxaca</strong> package. In particular, I use the Blinder-Oaxaca decomposition to explain the wage gap between native and foreign-born Hispanic workers in metropolitan Chicago. I analyze data from the <strong>chicago</strong> data frame, included in the <strong>oaxaca</strong> package:</p><p><strong>R&gt; data(“chicago”)</strong></p><p>The <strong>chicago</strong> data frame contains information about the demographic characteristics and labor market outcomes of 712 employed Hispanic workers in the Chicago metropolitan area. It is a subset of the 2013 Current Population Survey (CPS) Outgoing Rotation Groups (ORG) data set.</p><p>I am interested in decomposing the wage gap between native and foreign-born workers. The wage gap could be due to group differences in the level of wage determinants such as age, gender or education. Alternatively, the gap could arise from a differential effect of these determinants on native and immigrant workers’ wages. I call the <strong>oaxaca()</strong> function to estimate the relative magnitudes of these channels’ influence:</p><p><strong>R&gt; results &lt;- oaxaca(formula = real.wage ~ age + female + LTHS + <br> some.college + college + advanced.degree | foreign.born | LTHS +<br> some.college + college + advanced.degree, data = chicago, R = 1000)</strong></p><p>As the <strong>formula</strong> argument indicates, the outcome variable in this decomposition is <strong>real.wage</strong>, the worker’s real wage denominated in 2013 U.S. dollars. The values of the dependent variable had been obtained by exponentiating the natural logarithm of the workers’ real wages (contained in the provided <strong>ln.real.wage</strong> variable):</p><p><strong>R&gt; chicago$real.wage &lt;- exp(chicago$ln.real.wage)</strong></p><p>The linear regression model includes covariates that account for the workers’ age, gender and education. <strong>LTHS</strong> (“less than high school”), <strong>some.college</strong>, <strong>college</strong> and <strong>advanced.degree</strong> are indicator variables that denote the highest level of education an individual has achieved. A high school education is the omitted baseline category. The variable <strong>foreign.born</strong> indicates whether a worker was born outside of the United States. Group A consists of native workers, and Group B of foreign-born ones. To make sure that the choice of the omitted baseline does not affect the decomposition estimates, the <strong>formula</strong> argument also specifies that the categorical variables denoting the education level ought to be adjusted. Bootstrapped standard errors are calculated based on 1,000 replicates.</p><p><strong>R&gt; results$n</strong></p><p><strong>$n.A<br>[1] 287</strong></p><p><strong>$n.B<br>[1] 379</strong></p><p><strong>$n.pooled<br>[1] 666</strong></p><p>The <strong>n</strong> component of the resulting <strong>“oaxaca”</strong>-class object indicates that there are 287 native and 379 foreign-born workers in the analyzed sample. The pooled analysis contains 666 observations.</p><p><strong>R&gt; results$y</strong></p><p><strong>$y.A<br>[1] 17.58282</strong></p><p><strong>$y.B<br>[1] 14.56725</strong></p><p><strong>$y.diff<br>[1] 3.015574</strong></p><p>The <strong>y</strong> component of the resulting <strong>“oaxaca”</strong>-class object indicates that the mean real wage is $17.58 for the natives (Group A) and $14.57 for foreign-born workers, leaving the difference of approximately $3.02 to be explained by the Blinder-Oaxaca decomposition.</p><p><strong>Threefold Decomposition</strong></p><p>First, I look at the results of the threefold Blinder-Oaxaca decomposition:</p><p><strong>R&gt; results$threefold$overall</strong></p><figure><img alt="" src="https://cdn-images-1.medium.com/max/911/1*F54teFge41BKYzYp1UKvKw.png" /></figure><p>The results of the threefold decomposition suggest that, of the $3.02 difference, approximately $1.62 can be attributed to group differences in endowments (i.e., age, gender, education), $2.83 to differences in coefficients, and the remaining -$1.43 is accounted for by the interaction of the two. Next, I examine the endowments and coefficients components of the threefold decomposition variable by variable. This is most easily done by using the <strong>plot()</strong> method:</p><p><strong>R&gt; plot(results, components = c(“endowments”,”coefficients”))</strong></p><p><em>Figure 1</em> shows the estimation results for each variable, along with error bars that indicate 95% confidence intervals. In the endowments component, most variables appear to have a statistically insignificant (or only marginally significant) influence, with the sole exception of <strong>LTHS</strong>. It seems that a significant portion of the native-immigrant wage gap is driven by group differences in the proportion of individuals with less than a high school education.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/833/1*Uw289Jtc676hr_pihddsag.png" /><figcaption>Figure 1: The endowments and coefficients components of a threefold Blinder-Oaxaca decomposition of the native vs. immigrant wage gap.</figcaption></figure><p><strong>R&gt; summary(results$reg$reg.pooled.2)$coefficients[“LTHS”,]</strong></p><figure><img alt="" src="https://cdn-images-1.medium.com/max/539/1*NBRgJDS0vcb5iIVECEfwOA.png" /></figure><p><strong>R&gt; results$x$x.mean.diff[“LTHS”]<br><br> LTHS <br>-0.2693959</strong></p><p>Individuals with less human capital tend to earn less, as can be seen from the pooled regression coefficient on <strong>LTHS</strong> reported above. Furthermore, the value of <strong>x.mean.diff</strong> shows that a greater proportion of foreign-born Hispanic workers have not attained a high school education. The difference in the educational composition of native and immigrant worker groups thus accounts for some portion of the natives’ higher wages.</p><p>Similarly, most variables are either insignificant or exhibit only marginal statistical significance in the coefficients component. The only variable which achieves clear statistical significance is <strong>age</strong>.</p><p><strong>R&gt; results$beta$beta.diff[“age”]</strong></p><p><strong>age <br>0.1860063</strong></p><p>As the difference in the <strong>age</strong> coefficients between natives and immigrants shows, the wage payoff of an additional year of age is greater for U.S.-born Hispanic workers by almost 19 cents. As <em>Figure 1</em> makes clear, differences in the regression coefficients on <em>age</em> account for the decisive portion of the wage gap.</p><p><strong>Twofold Decomposition</strong></p><p>Next, I look at the results of the twofold Blinder-Oaxaca decomposition. In the output below, the <strong>group.weight</strong> column indicates the relative weights of coefficients from a regression on observations from Groups A and B, respectively, in the reference coefficient vector. The two negative weights indicate that the reference coefficients come from pooled regressions either without (<strong>-1</strong>) or with (<strong>-2</strong>) the group indicator variable included as a covariate.</p><p><strong>R&gt; results$twofold$overall</strong></p><figure><img alt="" src="https://cdn-images-1.medium.com/max/909/1*qIgnS7eHBRVyvHcZ0B6Chg.png" /></figure><p>For presentational ease, I focus my discussion on the decomposition that uses pooled regression coefficients (from a regression that does not include the group indicator variable <strong>foreign.born</strong>) as the reference coefficient set. This decomposition is denoted by <strong>-1</strong> in the <strong>weights</strong> column. The results of the overall twofold decomposition indicate that the $3.02 wage gap between native and foreign-born Hispanic workers can be decomposed into $1.36 that can be explained by group differences in the explanatory variables and $1.66 that is unexplained.</p><p>Let us assume that the unexplained component of the wage gap occurs due to labor market discrimination, and that the pooled regression coefficients are non-discriminatory. The Blinder-Oaxaca decomposition would then also indicate that $0.94 of the unexplained part originates from discrimination in favor of native Hispanic workers (component “<strong>unexplained A</strong>”), while $0.72 comes from discrimination against those who are born outside of the United States (component “<strong>unexplained B</strong>”). The standard errors provide a sense of the uncertainty that accompanies all of the point estimates.</p><p><strong>R&gt; plot(results, decomposition = “twofold”, group.weight = -1)</strong></p><p><em>Figure 2</em> provides a variable-by-variable twofold decomposition. The results are consistent with the threefold composition. It appears that the wage gap is driven largely by the lower proportion of workers with less than a high school education among the natives (in the explained component) and by the native workers’ greater returns to age.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/825/1*y1Inyx-5U4fcESJnWOMq_w.png" /><figcaption>Figure 2: The explained and unexplained components of a twofold Blinder-Oaxaca decomposition of the native vs. immigrant wage gap.</figcaption></figure><p>I can explore the unexplained component even further. In <em>Figure 3</em>, I examine three variables from the decomposition — <strong>age</strong>, <strong>female</strong> and <strong>college</strong> — and visualize how much of the unexplained portion of the wage gap can be attributed to discrimination in favor of the natives, and how much is due to discrimination against the immigrants.</p><p><strong>R&gt; plot(results, decomposition = “twofold”, weight = -1,<br> unexplained.split = TRUE, components = c(“unexplained A”, <br> “unexplained B”), component.labels = c(“unexplained A” = <br> “In Favor of Natives”, “unexplained B” = “Against the Foreign-Born”),<br> variables = c(“age”, “female”, “college”), variable.labels = c(“age” =<br> “Years of Age”, “female” = “Female”, “college” = “College Education”))</strong></p><p>I use a variety of <strong>plot()</strong> method arguments to customize the formatting of the resulting bar graph. Through the <strong>components</strong> and <strong>component.labels</strong> arguments, I choose to display only the two subparts — “<strong>unexplained A</strong>” (i.e., discrimination in favor of Group A) and “<strong>unexplained B</strong>” (discrimination against Group B) — of the unexplained decomposition component, and attach appropriate labels to them. Similarly, I use the <strong>variables</strong> and <strong>variable.labels</strong> arguments to select and label the variables I examine. Here’s the result:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/719/1*h1g8XhzPIY4rBlhex5Kyhw.png" /><figcaption>Figure 3: The unexplained portion’s discrimination sub-components in a twofold Blinder-Oaxaca decomposition of the native vs. immigrant wage gap.</figcaption></figure><p>It appears that only the discrimination components for the <strong>age</strong> variable (labeled “Years of Age” in the bar graph) achieve non-marginal statistical significance. The relative size of the bars suggests that — if we assume that the pooled regression coefficients reflect a state of non-discrimination — almost twice as much of the wage gap is explained by discrimination against foreign-born workers as it is by discrimination in favor of native ones.</p><p>The comparison would be a little easier to make if the discrimination components bar charts were presented side-by-side for each variable separately. This can be achieved by switching on the <strong>component.left</strong> argument in the <strong>plot()</strong> method. The resulting bar graph is presented in <em>Figure 4.</em></p><p><strong>R&gt; plot(results, decomposition = “twofold”, weight = -1,<br> unexplained.split = TRUE, components = c(“unexplained A”, <br> “unexplained B”), component.labels = c(“unexplained A” = <br> “In Favor of Natives”, “unexplained B” = “Against the Foreign-Born”),<br> component.left = TRUE, variables = c(“age”,”female”,”college”),<br> variable.labels = c(“age” = “Years of Age”, “female” = “Female”,<br> “college” = “College Education”))</strong></p><figure><img alt="" src="https://cdn-images-1.medium.com/max/733/1*CPuHVbc0k6XYI0xqUIQtcA.png" /><figcaption>Figure 4: The unexplained portion’s discrimination sub-components in a twofold Blinder-Oaxaca decomposition of the native vs. immigrant wage gap. An alternative presentation.</figcaption></figure><p>Specific numerical values of the point estimates of the unexplained discrimination components can, of course, be obtained directly from the <strong>“oaxaca”</strong>-class object:</p><p><strong>R&gt; variables &lt;- c(“age”, “female”, “college”)<br>R&gt; columns &lt;- c(“group.weight”, “coef(unexplained A)”, “coef(unexplained B)”)<br>R&gt; results$twofold$variables[[5]][variables, columns]</strong></p><figure><img alt="" src="https://cdn-images-1.medium.com/max/683/1*xZZhhaRTurwIdWW8eYJk2g.png" /></figure><p>To summarize, I have used the Blinder-Oaxaca decomposition to examine the wage gap between native and foreign-born Hispanic workers in the Chicago metropolitan area. The results of my analysis suggest that much of the gap can be explained by two facts:</p><ul><li>There are more workers with less than a high school education in the foreign-born group. Workers with a lower stock of human capital tend to command lower wages in the labor market. As a result, the relatively less-educated group of foreign-born Hispanic workers will, on average, earn lower wages than their native counterparts.</li><li>The returns to age are greater for native workers than for the immigrants. In other words, even if the foreign-born workers had the same average age as the natives, the native group would, on average, earn higher wages than immigrants. This result makes some intuitive sense if we interpret age as potentially picking up the effect of labor market experience. The higher returns to age among the natives may, for instance, reflect the differential availability of more lucrative jobs with greater opportunities for career growth.</li></ul><p>In this two-part article, I have introduced the <strong>oaxaca</strong> package for the <strong>R</strong> statistical programming language. It is the first <strong>R</strong> package that allows researchers to estimate Blinder-Oaxaca decompositions, a statistical method that decomposes differences in mean outcomes across two groups into a part that is due to group differences in the levels of explanatory variables and a part that is due to differential magnitudes of regression coefficients.</p><p><strong>oaxaca</strong> estimates threefold and twofold Blinder-Oaxaca decompositions for linear models, and also provides estimates for a detailed, variable-by-variable decomposition. Each point estimate is presented with a bootstrapped standard error that measures the corresponding estimation uncertainty. <a href="https://medium.com/@MarekHlavac/package-oaxaca-for-blinder-oaxaca-decomposition-in-r-part-1-introduction-and-theory-b8dafb085a31">Part 1</a> introduced some of the theory behind these decompostion.</p><p>Here, in Part 2, I have demonstrated the package’s capabilities through an empirical example that examines the wage gap between native and foreign-born Hispanic workers in the Chicago metropolitan area. In doing so, I have also showcased the <strong>oaxaca</strong> package’s unique visualization features that allow users to graphically summarize the results of their decompositions.</p><p><strong>About the author: </strong>Marek Hlavac teaches economics at <a href="https://www.uwcad.it/">UWC Adriatic</a>, an international secondary school in Duino (Trieste), Italy. In addition, he is a research fellow at the <a href="http://celsi.sk/en/">Central European Labour Studies Institute (CELSI)</a> in Bratislava, Slovakia. He holds a Bachelor’s degree in Economics from Princeton University, a Master’s degree in Public Policy from Georgetown University, and a Ph.D. in Political Economy and Government from Harvard University. You can find his personal website <a href="https://sites.google.com/site/marekhlavac/">here</a>.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=12222e9a886d" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Package “oaxaca” for Blinder-Oaxaca Decomposition in R — Part 1: Introduction and Theory]]></title>
            <link>https://medium.com/@MarekHlavac/package-oaxaca-for-blinder-oaxaca-decomposition-in-r-part-1-introduction-and-theory-b8dafb085a31?source=rss-bcf2a64a4cae------2</link>
            <guid isPermaLink="false">https://medium.com/p/b8dafb085a31</guid>
            <category><![CDATA[economics]]></category>
            <category><![CDATA[r]]></category>
            <category><![CDATA[data-science]]></category>
            <category><![CDATA[labor-market]]></category>
            <category><![CDATA[discrimination]]></category>
            <dc:creator><![CDATA[Marek Hlavac]]></dc:creator>
            <pubDate>Wed, 03 Jan 2018 07:32:41 GMT</pubDate>
            <atom:updated>2018-01-03T07:37:21.145Z</atom:updated>
            <content:encoded><![CDATA[<p><em>The text that follows is an abridged and simplified version of the documentation vignette for my </em><strong><em>oaxaca</em></strong><em> R package. Part 1, below, introduces the package and explains some econometric theory behind the Blinder-Oaxaca decomposition. </em><a href="https://medium.com/@MarekHlavac/package-oaxaca-for-blinder-oaxaca-decomposition-in-r-part-2-features-and-example-12222e9a886d"><em>Part 2</em></a><em> presents specific features of the </em><strong><em>oaxaca</em></strong><em> package, and illustrates their use with a real-world example. For a more complete treatment with full academic citations and references, please refer to the </em><a href="https://cran.r-project.org/web/packages/oaxaca/vignettes/oaxaca.pdf"><em>full article</em></a><em>.</em></p><p>If you use the <strong>oaxaca </strong>package in your research, please do not forget to cite it:</p><blockquote>Hlavac, Marek. (2018). oaxaca: Blinder-Oaxaca Decomposition in R. R package version 0.1.4. <a href="https://cran.r-project.org/package=oaxaca">https://CRAN.R-project.org/package=oaxaca</a></blockquote><p><strong>Abstract: </strong>This article introduces the <strong>R</strong> package <strong>oaxaca</strong> to perform the Blinder-Oaxaca decomposition, a statistical method that decomposes the gap in mean outcomes across two groups into a portion that is due to differences in group characteristics and a portion that cannot be explained by such differences. Although this method has been most widely used to study gender- and race-based discrimination in the labor market, Blinder-Oaxaca decompositions can be applied to explain differences in any continuous outcome across any two groups. The <strong>oaxaca</strong> package implements all the most commonly used variants of the Blinder-Oaxaca decomposition for linear regression models, calculates bootstrapped standard errors for its estimates, and allows users to visualize the decomposition results.</p><h3>Introduction</h3><p>In this article, I introduce the <strong>R</strong> package <strong>oaxaca</strong> to estimate Blinder-Oaxaca decompositions for linear regression models. The Blinder-Oaxaca decomposition is a statistical method that decomposes differences in mean outcomes across two groups into a part that is due to group differences in the levels of explanatory variables and a part that is due to differential magnitudes of regression coefficients.</p><p>The Blinder-Oaxaca decomposition originated and has been widely used in the study of labor market discrimination. Economists and sociologists have, for instance, used it to decompose wage and earnings differences based on gender and race. Although Blinder-Oaxaca decompositions have been a mainstay of empirical research on discrimination, they can be, in principle, applied to explain differences in any continuous outcome across any two groups. Researchers have, for instance, used it to examine the assimilation of immigrants, school enrollment rates, health insurance coverage, the prevalence of smoking, or even local hunting lease rates.</p><p>The <strong>oaxaca</strong> package is the first Blinder-Oaxaca decomposition package for the <strong>R</strong> statistical programming language. It implements several types of the decomposition for linear regression models, and obtains point estimates of all decomposition components using the same estimation procedures as the module <strong>oaxaca</strong> (by Ben Jann). Standard errors are calculated using a non-parametric bootstrapping approach. Unlike any other existing software implementation of the Blinder-Oaxaca decomposition, <strong>oaxaca</strong> enables users to generate elegant bar graph visualizations of all decomposition results.</p><p>The package is available free of charge, and can be installed from the <a href="https://cran.r-project.org/web/packages/oaxaca/index.html">CRAN repository</a> in the usual way:</p><p><em>R&gt; install.packages(“oaxaca”)</em></p><h3>Blinder-Oaxaca Decomposition</h3><p>The aim of the Blinder-Oaxaca decomposition — first introduced by economists Alan Blinder and Ronald Oaxaca — is to explain how much of the difference in mean outcomes across two groups is due to group differences in the levels of explanatory variables, and how much is due to differences in the magnitude of regression coefficients. I will label the two groups as Group A and Group B. The mean outcome difference to be explained is simply the difference of the mean outcomes for observations in Group A and Group B:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/255/1*33Be2SFwYWvBtCfDBC69zA.png" /></figure><p><strong>Threefold Decomposition</strong></p><p>In the context of a linear regression, the mean outcome for each group can be expressed as the product of the mean values of explanatory variables and estimated regression coefficients. Hence, the expression above can be rewritten as:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/371/1*abdvgE9iFSaW41VZlT1zzA.png" /></figure><p>This expression can, in turn, be written as the sum of the following three terms:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1008/1*mumGBTpN4jnkK7EifVhulg.png" /></figure><p>This is the threefold Blinder-Oaxaca decomposition of the mean outcome difference. The endowments term represents the contribution of differences in explanatory variables across groups, and the coefficients term is the part that is due to group differences in the coefficients. Finally, the interaction term accounts for the fact that cross-group differences in explanatory variables and coefficients can occur at the same time.</p><p>The threefold decomposition can also be estimated separately for each explanatory variable:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*5xUX84caY3W2xsM-LNjXxw.png" /></figure><p><strong>Twofold Decomposition</strong></p><p>Alternatively, one can estimate a twofold Blinder-Oaxaca decomposition. The twofold approach decomposes the mean outcome difference with respect to a vector of reference coefficients. In the research literature on labor market discrimination, the reference coefficient vector has typically been interpreted to be non-discriminatory — in other words, as the set of regression coefficients that would emerge in a world of no labor market discrimination.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/893/1*g8Av5KRadYaYRB6098Daxg.png" /></figure><p>As the equation above shows, the twofold decomposition divides the difference in mean outcomes into a portion that is explained by cross-group differences in the explanatory variables, and a part that remains unexplained by these differences.</p><p>The unexplained portion of the mean outcome gap has often been attributed to discrimination, but may also result from the influence of unobserved variables. It can be further decomposed into two sub-components, labeled “unexplained A” and “unexplained B.” If one interprets the reference coefficient vector to be non-discriminatory, these sub-components measure the part of the mean difference in outcomes that originates from discrimination in favor of Group A and the part that comes from discrimination against Group B, respectively.</p><p>Again, a detailed, variable-by-variable decomposition can also be estimated:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/925/1*pq5kOKcOsgt-z4QfHUll-A.png" /></figure><p>The choice of the reference coefficients is generally up to the researcher. In the literature on labor market discrimination, it is often assumed that only one of the two groups faces discrimination — for instance, that only women or members of ethnic minorities are discriminated against. In such cases, the reference coefficients will simply be the coefficients from a regression on observations from one of the groups (typically, the group that is assumed not to be discriminated against).</p><p>Some researchers have instead used a weighted average of the two groups’ estimated coefficients as the set of reference coefficients. We might, for example, give equal weight to coefficients from regressions on Group A and Group B observations:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/337/1*CqIFomiHTOFnM2Gl5RcMqg.png" /></figure><p>Alternatively, we could weigh the coefficients by the proportion of observations in the corresponding group:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/525/1*AjB6G03QBlIRSIplf5Plnw.png" /></figure><p>Other researchers still have advocated the use of coefficient estimates from a regression that pools observations from both Groups A and B, and that does or does not include the group indicator variable as an additional regressor. The <strong>oaxaca</strong> package estimates results for all of the aforementioned choices of reference coefficients, and also enables users to specify their own custom weights for each Group’s estimated coefficients in order to construct a weighted average-based set of reference coefficients.</p><p><strong>Sensitivity to the Choice of Omitted Baseline Category</strong></p><p>The results of Blinder-Oaxaca decompositions have been found to be sensitive to the researcher’s choice of the omitted baseline category when categorical variables are included as covariates. Typically, categorical explanatory variables are introduced as a set of indicator (“dummy”) variables on the right hand side. To avoid perfect multicollinearity, one of the dummy variables is usually omitted, and represents the baseline category. The coefficients on the remaining dummy variables are then interpreted as deviations from this omitted baseline. A linear regression model that contains a categorical explanatory variable may thus have the following general form:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/900/1*jgmPkg_F28Z153HkqeipvQ.png" /></figure><p>where <em>Di</em> such that <em>i = 1, …, k — 1</em> are indicator variables that represent individual levels of a categorical variable. Category <em>k</em> is the omitted baseline.</p><p>To ensure that the Blinder-Oaxaca decomposition results are invariant to the user’s choice of the omitted baseline category, <strong>oaxaca</strong> implements a procedure that transforms the above regression model into:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*NOaMtWmGhPdymxkG9I7L_g.png" /></figure><p>where the new regression coefficients on the indicator variables are calculated by adding or subtracting an adjustment amount <em>a</em> to/from the original coefficients. The adjustment amount is simply the sum of the original dummy coefficients <strong><em>β</em></strong> divided by <em>k</em>, the total number of categories:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/181/1*jE35ZMDi_cXqKTZ4rOnBiw.png" /></figure><p>The adjustment amount is then added to the original intercept:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/191/1*czuTxe6kuQbafmW56bN0TA.png" /></figure><p>and subtracted from each of the other regression coefficients:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/192/1*uMpvIDyA4G3M9W2P9XHIGw.png" /></figure><p>for <em>i = 1, …, k</em>. The adjusted coefficients, as well as the results of detailed variable-by-variable Blinder-Oaxaca decompositions, will remain the same regardless of the researcher’s choice of the omitted category <em>k</em>.</p><h3>Estimation Uncertainty</h3><p>The <strong>oaxaca</strong> package provides a measure of the estimation uncertainty that accompanies each of its decomposition estimates. In particular, it reports bootstrapped standard errors based on a user-specified number (<em>R</em>) of sampling replicates. The package uses the following procedures to calculate standard errors:</p><ol><li><em>R</em> resamples are randomly sampled with replacement from the relevant set of observations.</li><li>Decomposition estimates are calculated for each of the <em>R</em> resamples from Step 1.</li><li>The bootstrapped standard error is the standard deviation of the <em>R</em> decomposition estimates from Step 2.</li></ol><p><a href="https://medium.com/@MarekHlavac/package-oaxaca-for-blinder-oaxaca-decomposition-in-r-part-2-features-and-example-12222e9a886d"><em>Continued in Part 2</em></a><em>, which presents specific features of the </em><strong><em>oaxaca</em></strong><em> package, and illustrates their use with a real-world example.</em></p><p><strong>About the author: </strong>Marek Hlavac teaches economics at <a href="https://www.uwcad.it/">UWC Adriatic</a>, an international secondary school in Duino (Trieste), Italy. In addition, he is a research fellow at the <a href="http://celsi.sk/en/">Central European Labour Studies Institute (CELSI)</a> in Bratislava, Slovakia. He holds a Bachelor’s degree in Economics from Princeton University, a Master’s degree in Public Policy from Georgetown University, and a Ph.D. in Political Economy and Government from Harvard University. You can find his personal website <a href="https://sites.google.com/site/marekhlavac/">here</a>.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=b8dafb085a31" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Nobel Prize-Winning Contributions to Economics [online syllabus]]]></title>
            <link>https://medium.com/@MarekHlavac/nobel-prize-winning-contributions-to-economics-online-syllabus-cfea6b8e3d81?source=rss-bcf2a64a4cae------2</link>
            <guid isPermaLink="false">https://medium.com/p/cfea6b8e3d81</guid>
            <category><![CDATA[nobel-prize]]></category>
            <category><![CDATA[economics]]></category>
            <category><![CDATA[education]]></category>
            <dc:creator><![CDATA[Marek Hlavac]]></dc:creator>
            <pubDate>Sun, 19 Nov 2017 15:50:59 GMT</pubDate>
            <atom:updated>2017-11-19T15:50:59.484Z</atom:updated>
            <content:encoded><![CDATA[<p>I have published an online syllabus, complete with links to all readings, for my course on Nobel Prize-Winning Contributions to Economics. I used to teach this seminar to Harvard undergraduates between 2013 and 2016, and figured the course should live on.</p><p>To see the syllabus, click <a href="https://sites.google.com/view/nobel-economics-course/home">here</a>.</p><p>It provides a nice overview of the major subfields in economics through the examination of Nobel Prize-winning insights and their more recent applications. Enjoy!</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=cfea6b8e3d81" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Slovakia Regulates Too Many Professions for Its Own Good]]></title>
            <link>https://medium.com/@MarekHlavac/slovakia-regulates-too-many-professions-for-its-own-good-1d810ddb39f6?source=rss-bcf2a64a4cae------2</link>
            <guid isPermaLink="false">https://medium.com/p/1d810ddb39f6</guid>
            <category><![CDATA[politics]]></category>
            <category><![CDATA[slovakia]]></category>
            <category><![CDATA[economics]]></category>
            <dc:creator><![CDATA[Marek Hlavac]]></dc:creator>
            <pubDate>Wed, 19 Aug 2015 21:20:51 GMT</pubDate>
            <atom:updated>2015-08-19T21:21:43.174Z</atom:updated>
            <content:encoded><![CDATA[<p>In comparison with other European countries, Slovakia regulates entry into a relatively large number of professions. Regulated professions require the provider of services to meet certain qualification criteria. These criteria usually involve some minimum education or experience requirements, or the obligation to join a professional association.</p><p>One example is the requirement that medical doctors have university-level credentials in their discipline, or the internship requirement that law graduates have to complete before they become full-fledged attorneys. Other qualification criteria include certifications from special training courses that the law requires, for instance, tour guides to possess.</p><h4>Slovakia Among the Heaviest Regulators</h4><p>According to data from the European Commission’s database of regulated professions, Slovakia regulates as many as 311 professions. By comparison, the median number of regulated professions in the 32 countries of the European Union and the European Free Trade Association is only 160. We thus find ourselves in a rather unflattering fourth place in the ranking of Europe’s heaviest regulators. Only three countries regulate more professions, and they all, incidentally, happen to be our partners from the Visegrad Four: Hungary (408 regulated professions), the Czech Republic (398) and Poland (347). On the other end of the regulatory spectrum are countries that regulate the lowest number of professions — Lithuania (72 regulated professions), Sweden (88) and Estonia (97). In these countries, the qualification restrictions usually apply to professions in health care and social services.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/572/1*Fn-uDw6KGP6W-aEh0vTyOw.png" /></figure><h4>Regulation as Consumer Protection</h4><p>The most common justification for the regulation of entry into particular professions is the effort to protect the consumer. A worker who does not possess the expertise necessary to do his or her job well may harm the customer by providing a low-quality service. Occupational licensing therefore makes most sense in cases where a poorly done job could cause serious and irreversible harm to the consumer and in cases where it is difficult to determine the expertise and experience of the provider ahead of time.</p><p>As a result, occupational licensing is perhaps most clearly justified in the case of health care professions. A low-quality health care intervention can often have irreversibly negative consequences. The success (or otherwise) of a medical procedure, furthermore, often does not become apparent until several months or even years have passed. It is also frequently difficult to unambiguously attribute the worsening of someone’s health to any particular medical intervention. It should come as no surprise, then, that the entry into medical professions is regulated even in countries that otherwise regulate very few professions.</p><h4>Regulation as Protection from Competition</h4><p>Occupation licensing can, however, be a double-edged sword. The requirement of qualification criteria often acts as a barrier to entry. Instead of protecting the consumer and ensuring the delivery of high-quality services, occupation licensing often serves primarily to shield existing providers from potential competition.</p><p>As a result, consumer prices are often higher than those that would have prevailed on an unregulated market. Another consequence of overly stringent regulation and the attendant lack of competition tends to be the low quality of provided services, as dissatisfied customers do not have the option of procuring the services from another supplier.</p><p>And even if there remained enough competition after a profession has been regulated, many individuals would be likely to provide their services off the books, without paying taxes. Overbearing regulation could thus push providers into the informal economy, and would have a negative impact on the government budget.</p><h4>Finding the Right Balance</h4><p>If legislators and regulators care about the overall welfare of society, one of their most important tasks will be to weigh the benefits and costs of regulating individual professions, and to correctly determine the proper scope for such regulation.</p><p>If the low-quality delivery of a service can have a permanently negative impact on the consumer and if it is difficult to ascertain the provider’s expertise <em>ex ante</em>, relatively stringent occupational licensing might be appropriate. In most other cases, we should instead considering relaxing the qualification criteria somewhat.</p><p>The fact that Slovakia regulated substantially more professions than most other European countries suggest that there is scope for deregulation. In many occupations, such as in cosmetic services, the quality of service delivery can be guaranteed through other means — for instance, through relying on the provider’s incentive to maintain a good reputation. In some cases, we regulate professions that are particularly attractive for Slovakia who have experience from abroad — such as translation and interpretation services, or the teaching of foreign languages.</p><p>More competition would lead to a decrease in consumer prices and an increase in the quality of services. In addition, it would also open up new employment opportunities for enterprising individuals and, despite a lesser role for the state, would also increase government revenues.</p><p><em>Marek Hlavac is a Ph.D. candidate in Political Economy and Government at Harvard University.</em></p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=1d810ddb39f6" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Is Small Government Always the Best Solution?]]></title>
            <link>https://medium.com/@MarekHlavac/is-small-government-always-the-best-solution-b6bcc1a64536?source=rss-bcf2a64a4cae------2</link>
            <guid isPermaLink="false">https://medium.com/p/b6bcc1a64536</guid>
            <category><![CDATA[slovakia]]></category>
            <category><![CDATA[economics]]></category>
            <category><![CDATA[politics]]></category>
            <dc:creator><![CDATA[Marek Hlavac]]></dc:creator>
            <pubDate>Tue, 18 Aug 2015 21:53:30 GMT</pubDate>
            <atom:updated>2015-08-18T21:53:30.259Z</atom:updated>
            <content:encoded><![CDATA[<p>Across the world, the global economic crisis has renewed interest in issues related to economic inequalities among both lay and expert audiences. Debates about their origins, importance and possible mitigation measures can seem rather curious from a Slovak’s perspective. Many economists in Central and Eastern European countries are often uncritically convinced of the superiority of a small state — one that regulates markets only to a very limited extent. Given the negative historical experience with central planning, such convictions are perhaps understandable. Nevertheless, among advanced industrialized societies, we find multiple well-functioning varieties of capitalism.</p><h4>A Simple Model of the Welfare State<br>and Its Limitations</h4><p>The study of economic inequality has long preoccupied many academic economists, sociologists and political scientists. In academic circles, an article by Allan Meltzer and Scott Richard was particularly influential. Meltzer and Richard built a mathematical model that suggested that, in democratic countries with unequal incomes, one should expect a great deal of redistribution.</p><p>Low-earning votes will, according to this model, support economic measures that would redistribute resources to them at the expense of those who earn more. The wealthy will, however, not be completely expropriated, since even the poor voters realize that tax hikes or welfare payment increases decrease overall economic efficiency. As a result, such public policies can put at risk the government’s ability to redistribute a sufficient amount of resources.</p><p>Because Meltzer and Richard’s model of the welfare state was relatively simple and offered clear-cut predictions, it immediately became a foundation for many other studies of economic inequality. It soon became clear, however, that the model’s predictions do not correspond to reality. Countries with unequal incomes, in fact, redistribute less than countries that exhibit greater inequality. Relatively unequal countries such as the United States or the United Kingdom thus redistribute fewer resources than the relatively equal Nordic states such as Sweden or Norway.</p><h4>Liberal and Coordinated Market Economies</h4><p>The paradoxical finding that equal countries engage in a great deal of redistribution suggests that social policy cannot be reduced to a Robin Hood-like mechanism that takes from the rich and gives to the poor. It appears, instead, that a variety of other, still well-functioning, varieties of capitalist economies are possible.</p><p>British economist David Soskice and American political scientist Peter Hall classify advanced industrialized economies as belonging to one of two basic types: liberal and coordinated market economies.</p><p>In a liberal market economy — a model that we typically find in Anglo-Saxon countries — the government plays a relatively small role. Welfare payments are modest, targeted only exclusively at the poor, and designed to incentivize individuals to find employment as fast as possible.</p><p>The welfare state is more robust in coordinated market economies, where we find a relatively high level of welfare support. Often, coordinated economies also feature universal social insurance systems in health care and pensions.</p><p>Both liberal and coordinated market economies can ensure a high standard of living and fast rates of economic growth. Why is that so? In both varieties of capitalism, economic institutions complement one another and, in doing so, ensure that the overall economy remains efficient.</p><p>Danish political scientist Torben Iversen pointed out that a particularly important complementarity arises from the interplay between the welfare state and the educational system. According to Iversen, different welfare systems motivate individuals to acquire different types of skills. Such skills can be either general or specific. General skills are transferable and can be applied in many industries and occupations. Examples include managerial or communication skills, but can also include the ability to adjust to a new environment. Specific skills (such as, say, the ability to operate complicated pieces of machinery), on the other hand, are especially useful in particular industries or even in particular firms.</p><p>The strong welfare state that we find in coordinated market economies often offers its citizens protection against the termination of their jobs. This type of social policy gives individuals an incentive to acquire specific skills that will enable them to recoup their human capital investments. Relatively high welfare payments, furthermore, enable the unemployed to decline a job that does not take advantage of their specific skills.</p><p>By contrast, the limited role of the welfare state in liberal market economies incentivizes individuals to invest in general skills, as these will enable them to find new employment quickly, if the need arises.</p><h4>What About Central and Eastern Europe?</h4><p>Most of the existing research on varieties of capitalism has focused on the advanced economies of Western Europe, as these have had a long and uninterrupted history of capitalism. During the period when post-communist countries were undergoing a transition from a centrally planned to a market-based economy, countries such as Slovakia were difficult to classify as either liberal or coordinated.</p><p>The market economy has, however, already established solid roots in Central and Eastern Europe. The Swedish economist Magnus Feldmann, for instance, classified Estonia as an example of a liberal market economy that has undergone a swift and radical liberalization. On the other end of the continuum lies Slovenia as a representative of coordinated economies in the region. The Slovenian reforms unfolded more gradually, and retained a significant role for social dialogue. Despite their recent economic difficulties, both Estonia and Slovenia are regarded as the success stories of post-communist economic transitions.</p><h4>The Choice for Slovakia: Small or Big Government?</h4><p>The far-reaching reforms of the tax, welfare and pensions systems during the second Dzurinda government brought Slovakia closer to the Estonian model of liberal capitalism. A relatively small welfare state therefore represents, to an extent, the <em>status quo</em>.</p><p>In its current form, the Slovak welfare system motivates individuals to focus on acquiring general skills that can be easily transferred between occupations. Such a system can be useful if we, for instance, regard professional services as the future of the Slovak economy. A more significant role for the welfare state would, on the other hand, give people an incentive to build up skills that are more applicable in specific industries or firms.</p><p>The examples of Anglo-Saxon and Scandinavian countries, as well as of Estonia and Slovenia in the post-communist world, demonstrate that both liberal and coordinated market economies can promote prosperity. As the success of these economic models depends on mutual complementarities between economic institutions, a transition to a coordinated economy would required multiple extensive reforms. One risk inherent in such reforms is that we might end up with a mixed liberal-coordinated model that would, in the end, work less efficiently.</p><p>A choice between a small or a big government would also have implications for gender equality in Slovakia. A greater role for the welfare state could, perhaps somewhat paradoxically, threaten gender equality in the Slovak private sector. Women could find themselves at a disadvantage in the workplace, if, say, motherhood prevented them from investing in their specific skills.</p><p>As a consequence, we could expect a greater concentration of women in the public sector, as is the case, for instance, in Scandinavian countries. On the other hand, the preservation of a relatively limited welfare state will lead to a relatively equal position of men and women on the labor market.</p><p><em>Marek Hlavac is a Ph.D. candidate in Political Economy and Government at Harvard University.</em></p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=b6bcc1a64536" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Meet Marek Hlavac,
a Slovak Economist Who Helped the World Bank and the New York Mayor’s Office…]]></title>
            <link>https://medium.com/@MarekHlavac/meet-marek-hlavac-a-slovak-economist-who-helped-the-world-bank-and-the-new-york-mayor-s-office-b3c040231240?source=rss-bcf2a64a4cae------2</link>
            <guid isPermaLink="false">https://medium.com/p/b3c040231240</guid>
            <dc:creator><![CDATA[Marek Hlavac]]></dc:creator>
            <pubDate>Mon, 06 Jul 2015 01:36:19 GMT</pubDate>
            <atom:updated>2018-06-25T17:11:11.205Z</atom:updated>
            <content:encoded><![CDATA[<h3>Meet Marek Hlavac,<br>a Slovak Economist Who Helped the World Bank and the New York Mayor’s Office with Its Analyses</h3><p><a href="https://sites.google.com/site/marekhlavac/"><em>Marek Hlavac</em></a><em> is a proud native of Liptovsky Mikulas, Slovakia. When he was sixteen years old, he left for the </em><a href="http://uwcad.it/"><em>United World College of the Adriatic</em></a><em> in Italy, a prestigious international boarding school, to finish his secondary education. He then completed a bachelor’s degree in Economics and Finance at </em><a href="http://www.princeton.edu/main/"><em>Princeton University</em></a><em> and a master’s degree in Public Policy at </em><a href="https://mccourt.georgetown.edu/"><em>Georgetown University</em></a><em> in Washington, DC. He is currently a doctoral candidate in </em><a href="http://www.hks.harvard.edu/degrees/phd/peg"><em>Political Economy and Government at Harvard</em></a><em>. There, he teaches microeconomics, political economy, as well as a </em><a href="https://sites.google.com/site/marekhlavac/Hlavac_Ec970_Nobel_Contributions_Economics_Syllabus.pdf?attredirects=0"><em>seminar that surveys economics through the lens of Nobel Prize-winning contributions to the discipline</em></a><em>. His research has focused on international and comparative political economy, on labor economics, as well as on redistribution and immigration policy preferences.</em></p><p><em>In addition, Marek has worked for the </em><a href="https://www.google.com/url?sa=t&amp;rct=j&amp;q=&amp;esrc=s&amp;source=web&amp;cd=8&amp;cad=rja&amp;uact=8&amp;ved=0CFUQFjAH&amp;url=http%3A%2F%2Fecon.worldbank.org%2Fresearch&amp;ei=SsuZVbDTJYz2-QGcmYCABw&amp;usg=AFQjCNEjj8IwEVV9DZhqj4a2dPgHfr9wJw&amp;sig2=gFTG4UuwUpj_SASClM4oVw"><em>World Bank</em></a><em>, as well as for </em><a href="http://www.nera.com/index.html"><em>NERA Economic Consulting</em></a><em>, a private sector consultancy. He has also completed an internship at the </em><a href="http://www.brookings.edu/"><em>Brookings Institution</em></a><em>, a think tank in Washington, D.C. At Brookings, he helped construct </em><a href="http://www.cgdev.org/page/quality-oda-quoda"><em>an index that measures foreign aid effectiveness</em></a><em>. His statistical software “</em><a href="http://cran.r-project.org/web/packages/stargazer/index.html"><em>stargazer</em></a><em>” is used by tens of thousands of researchers all around the world. With </em><a href="http://explore.georgetown.edu/people/hjh4/?PageTemplateID=179"><em>Harry J. Holzer</em></a><em>, former Chief Economist at the U.S. Department of Labor, Marek has examined </em><a href="https://www.russellsage.org/sites/all/files/logan/logan_diversity_chapter2.pdf"><em>trends in the U.S. labor market over the past thirty years</em></a><em>. Last but not least, Marek has not forgotten about his mother tongue. He has launched </em><a href="https://sites.google.com/site/marekhlavac/slovak_lessons_beginner_lesson1"><em>online Slovak lessons for beginners</em></a><em>, and has taught the language to foreigners.</em></p><p><strong>How did you end up in Italy as a sixteen-year-old?</strong></p><p><strong>Marek:</strong> It all started with a complete coincidence. One day, I stayed in my school building for two more hours after classes ended, as I had to wait for a train that would take me home. I was pacing up and down the school corridors, and coincidentally came across a leaflet on one of the noticeboards that advertised a competition for scholarships at international boarding schools. I figured it might be an interesting opportunity. I was very interested in foreign languages at that time.</p><p>I applied, and ended up winning a scholarship to go the <a href="http://uwcad.it/">United World College of the Adriatic</a> in Italy, an international high school. The school was located close to the city of Trieste, near the border with Slovenia. The local population was ethnically mixed — about two thirds Italian, and one third Slovene.</p><p>The selection process took place in 2002 — perhaps one or two years before most Slovak households had access to the Internet. I was therefore not really able to investigate what kind of school I am enrolling in. I was, however, pleasantly surprised. And that is how the story of how I eventually ended up in the United States begins.</p><p><strong>Was your high school education similar to what it would have been in Slovakia?</strong></p><p><strong>Marek: </strong>The educational system was somewhat different. Nevertheless, I wasn’t starting from scratch. I built upon my educational background, and completed my last two years of secondary education in Italy. I participated in a two-year program that concluded with the International Baccalaureate, an international high school diploma. My school was very diverse. We had a hundred students in each year, and the students came from as many as eighty-five countries. There were two of us from Slovakia.</p><p><strong>You were quite young. Wasn’t it too early for you to leave for abroad?</strong></p><p><strong>Marek:</strong> It is difficult to say. I experienced some stress from a new environment, and had to get used to studying and communicating in English. My family thought I was leaving early, but I never felt that way. Simply put — an opportunity presented itself, and I took it.</p><p><strong>And you made excellent use of it. I assume that the high school in Italy opened the door to Princeton for you.</strong></p><p><strong>Marek: </strong>That’s exactly right. I received a scholarship to pursue a bachelor’s degree at <a href="http://www.princeton.edu/main/">Princeton University</a> in New Jersey. I studied economics and finance, and was awarded a prize for being the <a href="http://www.princeton.edu/economics/undergraduate/pdf/Class%20of%202008.pdf">top student in the Department of Economics</a>. My undergraduate thesis was also honored as the best economics thesis in my graduating year.</p><p><strong>Have you always wanted to study economics?</strong></p><p><strong>Marek: </strong>I have always been interested in the social sciences, history and public affairs. However, I only discovered economics in the United States. American higher education is very different from what we see in Slovakia. In Slovakia, you apply to a specific program — say, medicine or law. By contrast, in the United States, students have a lot more freedom of choice.</p><p>As soon as I came to Princeton, I enrolled in introductory microeconomics. In the second semester, I also completed an introductory course in macroeconomics. My professor was <a href="http://www.princeton.edu/~blinder/">Alan Blinder</a>, a very famous economist who also happened to be a great teacher. He was the main reason I chose to focus my undergraduate studies on economics. In addition to economics, I also completed coursework in psychology or history.</p><p>One major advantage of the U.S. educational system is that students have more time to find their true passion. An 18-year-old may often not know for sure what interests him or her most.</p><p><strong>In addition to studying at prestigious universities, you also completed a variety of other projects. Why don’t we start by introducing the ones you are most proud of?</strong></p><p><strong>Marek:</strong> I am proud of all of them. For instance, I worked on constructing an <a href="http://www.cgdev.org/page/quality-oda-quoda">index of foreign aid effectiveness</a> for the <a href="http://www.brookings.edu/">Brookings Institution</a>, a think tank in Washington D.C. It is always rewarding to see reports that rely on this index, as I know I wrote the computer programs that are behind the calculations.</p><p>I have also pursued various side projects outside of a professional setting. Some of these have been useful to quite a few people. Perhaps my favorite one was teaching the Slovak language to interested residents of Washington, D.C. In addition to working for the <a href="https://www.google.com/url?sa=t&amp;rct=j&amp;q=&amp;esrc=s&amp;source=web&amp;cd=8&amp;cad=rja&amp;uact=8&amp;ved=0CFUQFjAH&amp;url=http%3A%2F%2Fecon.worldbank.org%2Fresearch&amp;ei=qc-ZVbbpKITx-AGsqqjgBA&amp;usg=AFQjCNEjj8IwEVV9DZhqj4a2dPgHfr9wJw&amp;sig2=iVXP2Af7G2CL8I05oRzDFA&amp;bvm=bv.96952980,d.cWw">World Bank</a> and pursuing a <a href="https://mccourt.georgetown.edu/">Master in Public Policy degree</a>, I taught Slovak to a group of about 25 people on a weekly basis.</p><p><strong>Who is interested in studying Slovak in the United States?</strong></p><p><strong>Marek:</strong> One might think that there would not be a lot of interest in learning Slovak. Quite the contrary. Each week, I taught a class of 25 students, each of whom had his or her own story. Many of them were of Slovak descent. Perhaps they were students whose grandfather was Slovak, and they wanted to connect with their roots. Other had Slovak family members — often sons or daughters-in-law.</p><p>My youngest student was seventeen years old and took the Slovak course since he had already studied French and German, and simply wanted to learn yet another European language. My oldest student, on the other hand, was seventy-five years old. It was an older gentleman of Slovak descent. He had tried to learn Slovak for a long time, but found it difficult to do so on his own. In the end, he was very happy to find a Slovak course with an actual teacher.</p><p>I knew that this course might be the only opportunity for my students to learn the language. I also knew that each of my students has his or her own lives and priorities, and that some of them may not be able to attend every session. For this reason, <a href="https://sites.google.com/site/marekhlavac/slovak_lessons_beginner_lesson1">I put every lesson on the Internet</a>, complete with all phrases and their pronunciation. And as soon as the lessons appeared online, they took on a life of their own. People from all over the world were looking for Slovak lessons, and stumbled upon my website. Every now and then, I even get a thank-you e-mail.</p><p><strong>That is interesting. Many Slovaks would just teach their friends a couple of basic phrases, perhaps a handful of swear words, and that’s it. You, instead, created a whole set of lessons. This is a very beautiful example of promoting a positive image of Slovakia abroad. What kinds of people have been contacting you about the Slovak lessons?</strong></p><p>Perhaps my favorite e-mail came from a police director in England who was in charge of a unit that was taking care of immigrants and asylum seekers from Central Europe — mostly from Poland, the Czech Republic or Slovakia. He told me that he was using my website to learn how to communicate with these immigrants. I was quite pleased. It is a great feeling.</p><p><strong>You mentioned that you have worked for the World Bank. What projects were you working on?</strong></p><p><strong>Marek: </strong>I worked inside the World Bank headquarters in Washington, D.C., and focused on two research projects related to economic development. <a href="https://www.google.com/url?sa=t&amp;rct=j&amp;q=&amp;esrc=s&amp;source=web&amp;cd=1&amp;cad=rja&amp;uact=8&amp;ved=0CB4QFjAA&amp;url=http%3A%2F%2Fbelfercenter.ksg.harvard.edu%2Ffiles%2Fuploads%2Fmei%2Fconference%2Fandrabi-inaidwetrust.pdf&amp;ei=_s-ZVYDoHIOp-QG98bbYBA&amp;usg=AFQjCNFDgIuP-uLCmFD8z21y2cMswPi8Tw&amp;sig2=k_xWNQVeCIC2R7A6hf1qvQ&amp;bvm=bv.96952980,d.cWw">The first project analyzed the aftermath of a destructive earthquake that hit Pakistan in 2005. </a>We examined the effect the quake had on children’s ability to attend school, on the mental health of individual household memebrs, as well as on the reconstruction of educational and health care facilities. In addition to studying economic indicators, we also researched questions important for international diplomacy. One of our results indicates residents of areas, where foreign organizations participated in the reconstruction efforts, now show a greater level of trust in foreigners, including Americans and Europeans. Some of our results were even mentioned in the well-known Economist magazine. Our research wasn’t relegated to a drawer, and never looked at again. Instead, it made its way to the media, and may have been — to some extent — even been used by governments.</p><p><strong>What is it like to do economic research of this sort?</strong></p><p><strong>Marek: </strong>I analyzed a large amount of data collected from the field. The World Bank hires people in developing countries — in our case, in Pakistan — who administer surveys and collect the data we need. We then clean and analyze the data. Most importantly, we use statistical and econometric methods to find out how much influence an event, such as an earthquake, had on a variety of outcomes, such as mental health.</p><p>The other project I worked on at the World Bank also used data collected from the field, and focused on measuring the quality of health care provision in poor provinces in Central India. It was one of the first comprehensive studies of the health care facilities and provision in the area. Better knowledge of these important facts could enable national governments and international organizations to improve their policies, and to improve the effectiveness of foreign aid.</p><p><strong>Do you have any specific results? All of this sounds very general.</strong></p><p><strong>Marek:</strong> In the project that analyzed the quality of health care in India, we found that the providers of care are very diverse. Not all of them have a medical education. In the bigger and wealthier cities, one can find qualified doctors, but that is not necessarily the case in poorer area. In the poor villages, we may even find a single individual who is regarded by the rest of the village as a healer, even though he may or may not have a good grasp of medicine. Perhaps the most surprising result we found was that a doctor or a healer in central India is about as likely to hurt you as he is likely to help. Such a situation is quite similar to what Europe used to be like in the Middle Ages.</p><p><strong>How did you measure the quality of health care in India?</strong></p><p><strong>Marek: </strong>We asked doctors and healers about various scenarios. We told them to imagine a situation in which a patient presents a set of symptoms, and then ask them to propose a likely diagnosis. We also had some people observe what the health care provider actually did. A patient came in, and the whole visit was observed by a professional hired by the World Bank.</p><p>Each of these methods, of course, has its shortcomings. In the case of answering a questionnaire, the providers might be able to provide the correct diagnosis, but we cannot know what he or she would actually do in practice. When the healers are being observed, they may be behaving differently than they would without a World Bank professional in the room.</p><p>We addressed these concerns by coming up with yet another method. We sent out simulated patients who were actually healthy, but described symptoms consistent with an illness. They watched what the doctor told them, and then wrote down what they experienced. In this way, we were able to get a good idea about the doctor’s actual behavior — not only on paper, but also in practice.</p><p><strong>In what countries are these methods being used?</strong></p><p><strong>Marek: </strong>The World Bank focuses on less developed or middle income countries. Project like these would more likely be implemented in countries that are relatively poor.</p><p><strong>How did you get the World Bank job?</strong></p><p><strong>Marek:</strong> When I came to Washington, D.C., to pursue my Master’s degree in Public Policy, I knew I wanted to do more than just study. I really wanted to take advantage of the many opportunities that the city offered. I started sending out my resume to various organizations, research institutes and think tanks. I was able to land a position, in which I analyzed data.</p><p>I also had some previous work experience. Between my Bachelor’s and Master’s studies, I worked for an economic consulting firm, which produced expert reports for litigation disputes between firms in the health care sector. There was a point in time when I knew everything there is to know about how medical supplies are distributed to U.S. hospitals. I worked on a case in which two major manufacturers of hypodermic syringes were arguing over whether their contracts with hospitals were discriminatory.</p><p>This was just one of many projects. Another project was a <em>pro bono</em> case, in which we analyzed data about how the homeless are admitted to shelters in New York City. For three months, we observed how many homeless were admitted by the various shelters, and how long it took for shelter places to become available. Our findings contributed to the city’s decision to change the criteria that were used to allocate housing. The decision was announced at a press conference held by Mayor Michael Bloomberg.</p><p><strong>How serious is homelessness in New York?</strong></p><p><strong>Marek:</strong> New York City has a relatively high rate of homelessness, and the homeless are quite visible. If you walk down the street, you can easily run into a couple of homeless. The severity of the homelessness issue depends on multiple factors. One of them are the policies adopted by homeless shelters. For instance, if it takes a long time to obtain a spot in a shelter, homelessness rates will be increasing.</p><p><strong>You are twenty-eight years old, and have completed many successful projects already. What are you working on currently?</strong></p><p><strong>Marek:</strong> Since 2011, I have been a Ph.D. student at Harvard. I study political economy, and focus primarily on international political economy, labor economics, and on the study of immigration policy and redistribution preferences. I am also the author of several statistical software packages. One of them, <a href="http://cran.r-project.org/web/packages/stargazer/index.html">stargazer</a>, is being used by tens of thousands of researchers around the world. It is a tool for summarizing the results of statistical analyses. It wasn’t really part of my main research agenda. Rather, it started as a bit of a summer side project. As I continued to develop it, it became useful for an increasing number of researchers.</p><p><strong>Did this software start spreading through the Internet as well? Much like your online Slovak lessons?</strong></p><p><strong>Marek:</strong> Yes, exactly. A large community of users has developed around my software and similar projects. If a program is of high quality, it will almost spread by itself.</p><p><strong>We are getting back to your studies again. Earlier, I asked you about secondary education. Doctoral studies at Harvard must be quite different from those at Slovak universities…</strong></p><p><strong>Marek:</strong> At the beginning, a Ph.D. candidate has to complete some coursework. The fact that doctoral students have to do some teaching is not that different from Slovakia. I teach microeconomic to students who are pursuing a Master’s degree in public policy. In the summer, I teach a course that provides an overview of economics to mid-career Master’s students. Many of these students are former high officials at various ministries in countries all around the world. I also teach my own course — a seminar about the Nobel Prize in Economics. That course is intended for second-year undergraduate students. Only about ten students can take it at a time. We meet twice a week for 90 minutes. Students must prepare for each class meeting. They have to read several research papers — especially papers that later became the basis for a Nobel Prize. In class, we then discuss these readings. At the end of the semester, each student must submit an original research paper that can touch on any topic related to economics.</p><p><strong>Are you a demanding teacher?</strong></p><p><strong>Marek: </strong>My expectations are quite high, and the students know it. I am lucky to teach very ambitious students at Harvard.</p><p><strong>Could you imagine yourself teaching in Slovakia in a couple of years?</strong></p><p><strong>Marek:</strong> It is possible, although I do not have any specific plans at the moment. Whatever happens, I would like my work to be useful not only for me personally and for the world as a whole, but also to my home country of Slovakia.</p><p><strong>What is your appraisal of the current economic situation in the world? Is the economic crisis about to end anytime soon?</strong></p><p><strong>Marek:</strong> There certainly has been a serious economic crisis. First, we had a financial crisis with many difficulties in the financial sector. These then translated to problems in the real economy, in manufacturing as well as in other economic areas. I do think, however, that the news is better today than it was five years ago. At least in the United States, the situation is improving, and unemployment is on the decline. New jobs are being created, and university graduates find it easier to find employment. The situation is, however, by no means ideal.</p><p>The economic prospects of Europe are a little more complicated. This is partly a consequence of the fact that the common currency, the euro, creates some additional complications. As a result, the policies of various countries may be more or less compatible with retaining the euro. I will say, however, that I am somewhat optimistic. We are doing better than before. The most serious risk, in my view, is that — even in spite of reforms and new regulations in the financial sector-a similar crisis could reoccur. We would return to a situation where the gross domestic product sharply falls, and it would only take a long time for production and employment to recover.</p><p><strong>Do you follow the situation in Slovakia?</strong></p><p><strong>Marek: </strong>Yes, I follow developments in Slovakia quite carefully. I notice, for instance, a lot of disturbing corruption scandals. Corruption does exist in other countries, but I have a feeling that many countries are less complacent about it than Slovakia. It is as though there was some kind of mood of corruption acceptance in Slovakia — the mistaken feeling that there is little that can be done about scandals like these.</p><p>If I return to Slovakia with an ambition to be active in public life, I hope that I can contribute to decreasing the level of complacency in society. I could even imagine a career in politics. It is exactly corruption scandals like these that discourage young people. Either they leave the country after giving up on their own countries, or — if they are already abroad — they decide against coming back. At the same time, I would like to note that I think that it is great for young Slovaks to get some experience outside of their own country. It is good to see how other societies work, as it can inspire them to improve their own country when they get back. Speaking for myself and for other Slovaks that I have met abroad, I can safely say that most of us want to help Slovakia, whether it be from abroad or upon our return.</p><p><em>This article is a translation of an interview conducted by </em><a href="http://www.expres.sk/redaktori/olga-oli-dzupinkova/"><em>Oľga “Oli” Džupinková</em></a><em> for Rádio Expres in Slovakia. The original interview (in Slovak), along with a brief audio clip, can be found </em><a href="http://www.expres.sk/37156/slovensky-ekonom-pomahal-pri-analyzach-svetovej-banky-aj-radnice-v-new-yorku/"><em>here</em></a><em>.</em></p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=b3c040231240" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[All for One, One for All]]></title>
            <link>https://medium.com/@MarekHlavac/all-for-one-one-for-all-4b91de6e3019?source=rss-bcf2a64a4cae------2</link>
            <guid isPermaLink="false">https://medium.com/p/4b91de6e3019</guid>
            <category><![CDATA[economics]]></category>
            <category><![CDATA[international-relations]]></category>
            <category><![CDATA[politics]]></category>
            <dc:creator><![CDATA[Marek Hlavac]]></dc:creator>
            <pubDate>Fri, 29 May 2015 09:57:46 GMT</pubDate>
            <atom:updated>2015-05-29T09:57:46.606Z</atom:updated>
            <content:encoded><![CDATA[<h3>Improving Public Services through the International Division of Labor</h3><p>The next small big thing is the international division of labor in the provision of public services. It means letting a different country provide many of the public goods and services that you have traditionally received from your own government. It may mean having your passport issued in a friendly neighboring state. It could also mean that your own government might be managing the welfare rolls of your country’s neighbors or perhaps even of an entire continent.</p><p>Countries should be allowed to specialize in the provision of particular public goods and services, and to provide them not only to their own citizens, but also to citizens of other partner countries. To maximize efficiency, each country would specialize in the public services it can provide at the lowest opportunity cost. Such division of labor would be a ‘small thing’ in that it would rely on the well-tested economic principle of comparative advantage. It would also a ‘big thing’ since it would boldly extend that proven principle far beyond its usual applications in private trade and military cooperation.</p><p>The international division of labor in public services provision would bring us closer to achieving several desirable goals: better public services, more influence for small states, and an increase in the credibility of collective security guarantees.</p><p>This essay is organized as follows. In the next section, I describe the benefits that cross-country specialization in the provision of public services would bring. I proceed to show how my proposal represents a simple yet ambitious extension of the principle of comparative advantage. Finally, I conclude by illustrating my argument using a real-world example of a public service that can be exchanged internationally — namely, the digital governance and cybersecurity policies adopted by Estonia.</p><h3>Divide and Conquer:<br>The Advantages of Specialization</h3><h4>Cost Savings</h4><p>First and foremost, with an international division of labor, <em>we could enjoy better public services at a much lower cost</em>. With specialization and subsequent exchange, each country would provide its most cost-effective public services at a much larger scale in order to satisfy demand from its partners.</p><p>Since the provision of many public services involves large overhead costs but generally only relatively small costs for each additional unit provided, the international division of labor would allow countries to exploit <em>economies of scale</em>. Furthermore, additional savings might come from<em> economies of scope</em>, as countries would likely end up specializing not just in a single type of public service, but rather in a cluster of related services.</p><p>The combination of comparative advantage and savings from economies of scale and scope would allow each of the collaborating countries to import the highest-quality public services from another at a fraction of what it would cost them to provide the services themselves.</p><p>Such savings might be particularly appealing in times that call for fiscal austerity (for instance, in the wake of debt crises) or in policy environments that require a great deal of budgetary discipline (e.g., within currency areas such as the euro zone). Reducing the cost of providing public services could also allow governments to channel more resources into policies that are more local by nature. Examples include investments in education, health care or law enforcement.</p><h4>Greater Role for Small States</h4><p>Secondly, dividing up the provision of government services across multiple states would <em>enable small states to achieve a greater role on the international scene</em>. Many small states have acquired deep knowledge and ability in some policy domains, and will therefore be able to specialize in the provision of public services that rely on their particular area of expertise.</p><p>As a result, compared to their population size or the size of their economy, small states would acquire an outsized influence on the international scene. This influence would, furthermore, be achieved organically through the countries’ own efforts. Such an improvement in international standing would arguably be preferable to one that is attained through often contested political means, such as through negotiated increases in the voting power in international organizations.</p><p>In fact, the ability to specialize in some public services and to provide them to many partner countries would likely become a source of national pride. The newfound sense of national pride would, moreover, be of the healthy sort. Instead of relying on jingoism or on potentially harmful perceptions of generalized national superiority, the patriotism would emerge from pride in a country’s achievement and also in its ability to cooperate with other partners. Such sentiments are conducive to greater international cooperation, and could thus be a boon for regional integration projects, such as the European Union or the Association of Southeast Asian Nations (ASEAN).</p><h4>More Credible Security Guarantees</h4><p>In an anarchic international system dominated by great powers with considerable military and economic prowess, small states often seek security in military alliances. The most prominent example is, of course, the North Atlantic Treaty Organization (NATO). The alliance currently consists of 28 independent member countries, many of which are small states with limited ability to defend themselves against foreign aggression on their own. Article 5 of the Washington Treaty of 1949, the founding document of the alliance, provides a formal security guarantee for NATO members:</p><blockquote>“The Parties agree that an armed attack against one or more of them in Europe or North America shall be considered an attack against them all and consequently they agree that, if such an armed attack occurs, each of them […] will assist the Party or Parties so attacked by taking forthwith, individually and in concert with the other Parties, such action as it deems necessary, including the use of armed force, to restore and maintain the security of the North Atlantic area.”</blockquote><p>Nevertheless, doubts have been raised about the credibility of the collective defence guarantee, especially when it comes to defending small states on the edge of the alliance. Such doubts have become especially topical with the recent Russian annexation of Crimea and continued meddling in eastern Ukraine. Even though the alliance has stepped up its military presence in the east, many of the NATO members on the Russian border face uncertainty about how willing the rest of the alliance would be to defend them if they became targets.</p><p>Specialization in the provision of some public services would make it more likely that military allies would be willing to defend their small state allies. It would be far costlier for an alliance to lose a small country member that may be responsible for, say, managing many other allies’ pension system rolls. The corollary of an increased international influence of small states is a greater willingness of partner countries to come to small states’ defense.</p><h3>Plus ҫa change?<br>Taking Comparative Advantage<br>One Step Further</h3><p>The benefits of specialization have been well-known since the early days of modern economics in the late 18th century. Adam Smith’s magnum opus The Wealth of Nations, first published in 1776, illustrates these benefits through the famous pin factory example:</p><blockquote>“[A] workman not educated to [the pin-making] business […] could scarce, perhaps, with his utmost industry, make one pin in a day, and certainly could not make twenty. But in the way in which this business is now carried on, not only the whole work is a peculiar trade, but it is divided into a number of branches. […] One man draws out the wire, another straightens it, a third cuts it, a fourth points it, [and] a fifth grinds it at the top. […] Each person, therefore, […] might be considered as making four thousand eight hundred pins in a day.”</blockquote><p>Similarly, the gains from voluntary exchange have been well-known to economists at least since the 19th century writings of the British political economist David Ricardo. In his 1817 book <em>On the Principles of Political Economy and Taxation</em>, Ricardo put forward the principle of comparative advantage. According to this principle, countries can benefit from trade if each country specializes in the production of products, in which it has a comparative advantage — i.e., products which it can produce at the lowest opportunity cost.</p><p>History has shown that specialization and the international division of labor can bring prosperity to countries whose economic policies embrace them. Countries that have liberalized their trade policies have been able to achieve faster rates of economic growth, and — as a result — have secured a higher standard of living for their people.</p><p>The most notable examples, of course, involve the world’s two most populous countries — China and India. Since the beginning of economic reforms under Deng Xiaoping in 1978, China has achieved spectacular rates of economic growth and poverty reduction. Similarly, in India, a great deal of economic progress resulted from the liberalizing reforms of 1991. Astoundingly, as Columbia University economist Xavier Sala-i-Martin has found, global economic inequality — when measured in terms of individuals’ incomes — has been on the decline, in great part thanks to the rise of China and India.</p><p>The adoption of the comparative advantage principle has been concentrated in cross-country trade within the private sector. In the public sector, specialization and the international division of labor has only made a significant mark in the domain of military cooperation.</p><p>The North Atlantic Treaty Organization (NATO) provides a case in point. At the 2010 Lisbon summit, NATO set out its “Smart Defense” approach to collective security. Based on the principles of specialization and cooperation, “Smart Defense” encourages the national militaries of each alliance member to specialize in particular mission areas. This approach has already seen success in past and present NATO missions, such as the alliance’s peacekeeping operations in Bosnia and Kosovo as well as its current engagements in Afghanistan. Often, small states have played a disproportionately important role in some aspects of the operations. Slovakia and the Czech Republic, for instance, have proven themselves to be leaders in removing land mines and in anti-chemical warfare, respectively.</p><p>Yet, the principle of comparative advantage applies to any setting in which opportunity costs are important. Such settings, of course, include many of the traditional roles that governments have — e.g., the maintenance of a welfare state, or the provision of services to the citizenry. The international division of labor can therefore be fruitfully extended to the provision of a large variety public goods and services.</p><h3>Illustrative Example:<br>Digital Governance and<br>Cybersecurity in Estonia</h3><p>Relative to all other European states, the small Baltic country of Estonia has developed an extraordinary level of competence in digital governance and cybersecurity. As the Economist magazine points out, in 2007, Estonia “became the first country to allow online voting in a general election. It has among the world’s zippiest broadband speeds and holds the record for start-ups per person. Its citizens […] have their health records stored in the digital cloud. Filing an annual tax return online, as 95% of Estonians do, takes about five minutes.”</p><p>Estonia’s most significant policy innovation is its digital identity scheme. As soon as an Estonian is born, the hospital issues a digital birth certificate. When they reach the age of fifteen, all Estonian residents are issued an electronic identification card. The card is quite versatile, and can be used in commercial transaction, in lieu of an electronic signature, as well as to vote in elections. At the same time, a great deal of emphasis is placed on cybersecurity and privacy. The Estonian government can only require citizens to provide the minimum necessary amount of information, and all collected data are well-encrypted.</p><p>Needless to say, Estonia’s digital governance and cybersecurity are far ahead of all other countries in the European Union. Furthermore, it seems unlikely that any other European countries would catch up soon. Why not allow Estonia to be in charge of digital governance and cybersecurity for all of the European Union, then? Europeans could benefit from cheap and high-quality e-government services. In addition, Estonia would see its stature on the international scene greatly enhanced, as it would now become Europe’s most important provider of digital governance services. Last but not least, Estonia’s security situation — an important consideration, given its location close to the recently emboldened Russia — would also improve, since the country’s NATO allies would now have a greater incentive to come to its aid if necessary.</p><p>The example of Estonia’s e-government services illustrates the extraordinary potential of an international division of labor in the provision of public services. The ball in now in the policy-makers’ court to make it happen, and thereby to bring better government services, a more equitable power balance across countries, and greater security to people all over the world. The time has come.</p><p><strong>Note:</strong> <em>The ideas put forward in this essay were presented to the 45th </em><a href="http://www.symposium.org/"><em>St. Gallen Symposium</em></a><em> that took place in May 2015 in St. Gallen, Switzerland. A video recording of the whole plenary session, titled “What is the Next Small Big Thing?” can be found </em><a href="https://www.youtube.com/watch?v=ulozoPHlkXw"><em>here</em></a><em>.</em></p><h3>Bibliography</h3><p>Chinn, Menzie D. and Jeffry Frieden. (2012). <em>Lost Decades: The Making of America’s Debt Crisis and the Long Recovery.</em> W.W. Norton &amp; Company. 1st Edition.</p><p>Chow, Gregory C. (2007). China’s Economic Transformation. Wiley-Blackwell, 2nd Edition.</p><p>The Economist. (2013). “How did Estonia become a leader in technology?” 30 July 2013. Available at: <a href="http://www.economist.com/blogs/economist-explains/2013/07/economist-explains-21">http://www.economist.com/blogs/economist-explains/2013/07/economist-explains-21</a></p><p>The Economist. (2014). “Estonia takes the plunge.” 28 June 2014. Available at: <a href="http://www.economist.com/news/international/21605923-national-identity-scheme-goes-global-estonia-takes-plunge">http://www.economist.com/news/international/21605923-national-identity-scheme-goes-global-estonia-takes-plunge</a></p><p>Eichengreen, Barry. (2010). “The Breakup of the Euro Area.” In: Alberto Alesina and Francesco Giavazzi (Eds.), <em>Europe and the Euro</em>.</p><p>Foust, Joshua. (2012). “’Smart Defense’: Should Europe’s Militaries Specialize?” <em>The Atlantic Monthly</em>, 17 May 2012. Available at:<br><a href="http://www.theatlantic.com/international/archive/2012/05/smart-defense-should-europes-militaries-specialize/257328/">http://www.theatlantic.com/international/archive/2012/05/smart-defense-should-europes-militaries-specialize/257328/</a></p><p>Kupchan, Charles A. and Clifford A. Kupchan. (1995). “The Promise of Collective Security,” <em>International Security</em>, Vol. 20, No. 1, 52–61.</p><p>Landmine &amp; Cluster Munition Monitor. “Slovakia.” Available at:<br><a href="http://www.the-monitor.org/index.php/publications/display?url=lm/2004/slovak.html">http://www.the-monitor.org/index.php/publications/display?url=lm/2004/slovak.html</a></p><p>North Atlantic Treaty Organization (NATO). “What Is Article 5?” Available at: <a href="http://www.nato.int/terrorism/five.htm">http://www.nato.int/terrorism/five.htm</a></p><p>North Atlantic Treaty Organization (NATO). “Smart Defence.” Available at:<br><a href="http://www.nato.int/cps/en/natolive/78125.htm">http://www.nato.int/cps/en/natolive/78125.htm</a></p><p>Monaghan, Andrew. (2014). “The Ukraine Crisis and NATO-Russia Relations,” <em>NATO Review</em>. Available at: <a href="http://www.nato.int/docu/review/2014/russia-ukraine-nato-crisis/Ukraine-crisis-NATO-Russia-relations/EN/index.htm">http://www.nato.int/docu/review/2014/russia-ukraine-nato-crisis/Ukraine-crisis-NATO-Russia-relations/EN/index.htm</a></p><p>Ricardo, David. (1812). <em>On the Principles of Political Economy and Taxation.</em><br>Available at: <a href="http://www.econlib.org/library/Ricardo/ricPCover.html">http://www.econlib.org/library/Ricardo/ricPCover.html</a></p><p>Sala-i-Martin, Xavier. (2006). “The World Distribution of Income: Falling Poverty and… Convergence, Period,” <em>Quarterly Journal of Economics</em>, Vol. 121, No. 2, 351–397.</p><p>Simon, Jeffrey. (2003). <em>NATO and the Czech and Slovak Republics: A Comparative Study in Civil-Military Relations.</em> Rowman &amp; Littlefield Publishers.</p><p>Smith, Adam. (1776).<em> An Inquiry into the Nature and Causes of the Wealth of Nations. </em>Available at: <a href="http://www.econlib.org/library/Smith/smWNCover.html">http://www.econlib.org/library/Smith/smWNCover.html</a></p><p>Vreeland, James Raymond. (2007). <em>The International Monetary Fund: Politics of Conditional Lending.</em> New York: Routledge.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=4b91de6e3019" width="1" height="1" alt="">]]></content:encoded>
        </item>
    </channel>
</rss>