knitr::opts_chunk$set(echo = TRUE)

UGvoters16

What is this?

UGvoters16 is a package for the counts of Ugandan registered voters for the 2016 presidential election provided by the Electoral Commision (EC) of Uganda. This package contains the number of registered voters by polling station. This "controversial" data was claimed to contain atleast 20,000 "ghost voters" by members of the Ugandan media because the total count from the each polling station are not equal to the totals reported by the Electoral Commission.

How to use it

Before you can use the data in R, you need to download it from Github using the following commands:

installed.packages("devtools")
devtools::install_git("git://github.com/emaasit/UGvoters16.git", branch = "master")
library(UGvoters16)

After loading the library, you can create a local data frame using the following command:

df1 <- voters
df2 <- analyzed
head(df1)
head(df2)

What can you do with it?

You can explore for yourself and see why the Ugandan media claimed it has atleast 20,000 "ghost voters".

Example Analysis

How many voters are registered

# what are the column names
names(df1)
names(df2)

# count the total number of analyzed voter counts
sum(df2$ANALYZED_VOTER_COUNT)


Emaasit/UGvoters16 documentation built on May 6, 2019, 3:46 p.m.