setwd("C:/Users/rhicks/Dropbox/TingleyCostaRica/ISQ/data/supplement")
library(foreign)
library(ei)
library(sp)

ei2<-read.dta("eidata2.dta")

formula = perc_yes ~ pct_yes_pres06 

dbuf2 <-ei(formula=formula, total="electores", data=ei2)

summary(dbuf2)


