Over a million developers have joined DZone.

Coffee and Productivity

· Agile Zone

Learn more about how DevOps teams must adopt a more agile development process, working in parallel instead of waiting on other teams to finish their components or for resources to become available, brought to you in partnership with CA Technologies.

On Twitter, I was asked if there were serious research papers published on coffee consumption and labour productivity. There are some papers on coffee breaks and productivity, e.g. Productivity Through Coffee Breaks, but I could not find anything on coffee consumption. Since I could not find any dataset with personal consumption (maybe I should start keeping tracks of my own consumption to run a study) I tried to find data for national consumption instead (even if we know that both are – clearly – not equivalent)

  • last year, Sabine published on http://backreaction.blogspot.fr/ a dataset with consumption of coffee, per country (and per unhabitants),
  • on http://en.wikipedia.org/ we can find a dataset with GDP per hour worked for some countries (which can be seen as a common  measure of the productivity of a country)

If we merge those two datasets, we get

> base=read.table(
+ "http://freakonometrics.free.fr/cafe.csv",
+ header=TRUE,sep=";",dec=",")
> b=base[!is.na(base$GDP.PPP),]
> plot(b[,3],b[,4],xlab="Coffee Consumption",
+ ylab="GDP per hour worked")
> text(b[,3],b[,4]+1.6,b[,1],cex=.6)
> library(splines)
> X=b[,3]
> Y=b[,4]
> B=data.frame(X,Y)
> reg=glm(Y~bs(X),data=B)
> y=predict(reg,newdata=data.frame(
+ X=seq(0,10,by=.1)))
> lines(seq(0,10,by=.1),y,col="red")

Discover the warning signs of DevOps Dysfunction and learn how to get back on the right track, brought to you in partnership with CA Technologies.

Topics:

Published at DZone with permission of Arthur Charpentier, DZone MVB. See the original article here.

Opinions expressed by DZone contributors are their own.

The best of DZone straight to your inbox.

SEE AN EXAMPLE
Please provide a valid email address.

Thanks for subscribing!

Awesome! Check your inbox to verify your email so you can start receiving the latest in tech news and resources.
Subscribe

{{ parent.title || parent.header.title}}

{{ parent.tldr }}

{{ parent.urlSource.name }}