Introduction

Economic theory tells us that labour productivity is a primary determinant of wages. However, many critics have suggested that this relationship has broken down, particularly in recent decades. This project will explore a fixed-effects regression to analyze the link between productivity and wages in a panel of OECD countries.

This project does not intend to be comprehensive — but rather, more of an experiment that provides some evidence on the topic from a variety of countries.

Data Sources

All of my data will come the OECD database. I download three data series in CSV files: labour productivity (GDP per hour worked), average annual wages, and average annual hours worked. I take the time period from 1990–2018, since this is the most data available from all three data-sets.

The full code and data-sets are available on my Github here.

The Project

First, I will bring each data-set into R. I also load a couple of standard packages I use in almost any project I undertake.

library(ggplot2)
library(dplyr)

#Bring in labour productivity data
GDPh <- read.csv("DP_LIVE_16062020201012437.csv")
#Bring in average annual wages
Wage <- read.csv("DP_LIVE_16062020201639206.csv")
#Bring in average annual hours worked
Hours <- read.csv("DP_LIVE_16062020202140847.csv")

Cleaning & Preparing the Data

As is normal for almost any project, the data will come in exactly the form we want it. The data from OECD is well laid out, but still requires some work to get it in the format needed. For each data series, I will rename a couple columns for ease of readability and then delete columns that I don’t need.

#GDP per hour
names(GDPh)[1] <- "Country"
names(GDPh)[7] <- "GDP.h"
GDPh <- GDPh[-c(2:5,8)]
#Annual wages
names(Wage)[1] <- "Country"
names(Wage)[7] <- "Wage"
Wage <- Wage[-c(2:5,8)]
#Hours worked per year
names(Hours)[1] <- "Country"
names(Hours)[7] <- "Hours.a"
Hours <- Hours[-c(2:5,8)]

From here, I can combine the data-sets into one data frame:

Comb <- merge(GDPh, Hours)
Comb <- merge(Comb, Wage)

This data-set includes the OECD as a whole as a country, which I don’t want to include (since I’m looking at individual countries). I need to remove these observations from my data. There is a few ways this could be accomplished, but I found a neat way to create a “not-in” function that is easy to use in this case.

#economics #data-science #r #economy #programming #data analysis

Does Productivity Increase Wages?
1.10 GEEK