# Let's create a data.frame with typical election results
# with the following parties and votes to return 10 seats:
my_election <- data.frame(
party=c("Yellow", "White", "Red", "Green", "Blue", "Pink"),
votes=c(47000, 16000, 15900, 12000, 6000, 3100))
largestRemainders(my_election$party,
my_election$votes, seats = 10, method="droop")
Run the code above in your browser using DataLab