King County Elections
919 Southwest Grady Way
Renton, WA 98057-2906

206-296-VOTE (8683)
TTY: Relay: 711
FAX: 206-296-0108

Hours:
Weekdays 8:30 a.m. - 4:30 p.m.

Open data

Tutorials on how to browse and manipulate election open data results

King County Elections releases its final electronic canvass results (e-Canvass) after certification of each election. The e-Canvass results contain detailed election information including the race, precinct, legislative district, county council district, counter group, candidate, registered voters, times counted, times blank voted and times over voted.

The e-Canvass results are available both as a downloadable file and as an online dataset through the King County Open Data website.

Start

This tutorial will cover some of the basics of browsing and manipulating Election result datasets in the Open Data site. To access all Election datasets, you can browse for those tagged with the keyword "elections". We'll use the Aug 2010 primary election dataset as our sample for this tutorial.

Ballot drop box photo Bringing up the dataset shows all results for the Aug 2010 primary election broken down by race and precinct. The dataset is presented in tabular format much like it would be if viewed in a spreadsheet application (ie Excel). Each record contains the vote "count" for a particular candidate, in a specific race, within a specific precinct. The "candidates" column not only includes the actual candidates but also different counter types for that particular race and precinct. These counter types include the number of write-in votes, registered voters, times counted, times blank voted and times over voted.

The Open Data site gives users the tools to browse, sort, filter, group results and save different "views" of the original data set. We'll walk through some common scenarios for election results data through two main tutorials.

  • View results for a particular race and/or district (Filtering)
  • View cumulative results (Roll-up)

Tutorial: View results for a particular race and/or district (Filtering)

A common request when browsing results is to break it down by a particular race or district (Legislative, County or Congressional) In this example, we'll lookup the results for the State Supreme Court Justice Position No. 1 race. With the Open Data site, you would use the filter feature (blue button, upper right) to filter the data set for a particular value. In this case, we're filtering for the value "State Supreme Court Justice Position No. 1 nonpartisan office" in the RACE column.

Video tutorial

Click the arrow to start play

Instructions

  1. Selecting the Filter feature will bring up the Filter pane on the right hand side
  2. Select Filter, Sort, Roll-up to create a new filter
  3. With the form up, select the Filter checkbox, Match "all conditions", select Column "RACE", Operator "equals", and Value "State Supreme Court Justice Position No. 1 nonpartisan office"
  4. Select Apply to view the results
  5. This result set shows all results in the Race "State Supreme Court Justice Position No. 1 nonpartisan office" for the Aug 2010 primary election

Its important if you use the "equals" operator that the value provided in the filter matches exactly the race name in the RACE column. The "contains" or "starts with" operators can be used to match keywords or parts of the race name. From here, you can add additional conditions. Say to filter out just by Legislative District and/or Candidate. Here, we will two additional conditions to narrow the result set down to Legislative District 5.

Tutorial: View cumulative results (Roll-up)

The above examples produce a result set with counts for individual races, precincts and candidates but do not show any aggregate cumulative totals. Continuing with the Justice position 1 results, we can add a "Roll-Up" to help produce aggregate totals for each candidate.

Video tutorial

Click the arrow to start play

Instructions

  1. Select the "Roll-Ups & Drill-Downs" checkbox
  2. We want to get totals for each candidate so under Group By, select "Candidate"
  3. Under Roll-Up, select "COUNT" and then Function "Sum"
    In essence, we are grouping our result set by the candidate, and then adding up the values in the COUNT column for each group.
  4. Select Apply to view the results.
  5. This will give us the vote totals across all precincts for each candidate in the "State Supreme Court Justice Position No. 1 nonpartisan office" race in Legislative district 5.

Saving views

You can save the filters and the new result set as a view on the Open Data site. This will allow you save and edit the filters themselves and the results they produce without modifying the original data set. You must be a registered user and be signed in to save a view. https://www.datakc.org/signup

Exporting

In addition to saving a view of the results, you can save your work by downloading a copy of the filtered results set. The Open Data site allows you to download to a number of formats including CSV, Excel and PDF.