Election Results Tool

Summary

This tool transfers tabular election data into a set of features and a related candidate information table for use in the Election Results solution.

Before running the tool, verify that the election districts (precincts, counties, and so on) have been published as feature layers (ArcGIS Online or Portal for ArcGIS) or exist in a feature service (ArcGIS for Server or ArcGIS Enterprise), and that they are participating in a geodatabase relationship with a table for the candidate information using district identifiers for keys.

Parameters

Parameter Explanation Data Type
Input Spreadsheet (in_features) Spreadsheet (TXT tab-delimited, CSV, xls, xlsx) containing the election results that will be used to update the services. Table
District ID Field - Spreadsheet (ss_precinct_fld) Input spreadsheet field containing the identifiers for the election result geography. These could be county names, precinct IDs, district IDs, and so on. For example: PRECINCTID, COUNTY. Field
Candidate Fields - Spreadsheet (ss_candidate_info) Input spreadsheet fields containing the information for each candidate. Choose the field or fields containing candidate names and the number of votes received. Optionally, fields can also be specified for party affiliation and the percentage of the district vote received by each candidate. Field
Winning Party Field - Spreadsheet (ss_winner_fld) (Optional) Optional spreadsheet field containing the name of the winning candidate's party in each district. Field
Number of Ballots Field - Spreadsheet (ss_ballots_fld) (Optional) Optional spreadsheet field containing the total number of ballots cast in each district. Field
These results are updating a service published using: (pub_env) This tool can update services that have been published using ArcGIS Online, ArcGIS for Server, and Portal for ArcGIS. Choose the method used to publish the service that will be updated with these results. For ArcGIS Online services, this value should be the URL to your organization. For example, http://myorganization.maps.arcgis.com. For Portal for ArcGIS services, this value should be the URL of the servers REST endpoint. For example http://webadaptor.domain.com:6080/arcgis or https://webadaptor.domain.com:6443/arcgis. String
Organization URL (org_url) (Optional) This parameter is required if the service was published using either ArcGIS Online or Portal for ArcGIS. String
Username (username) (Optional) Organizational account for ArcGIS Online or Portal for ArcGIS with administrative access to the service. This could be the service owner or an administrative account. This parameter is required for ArcGIS Online and Portal for ArcGIS services. String
Password (password) (Optional) Password corresponding to the provided username. This parameter is required for ArcGIS Online and Portal for ArcGIS services. String
Feature Layer URL (service_url) (Optional) REST endpoint of a feature layer (including layer index value) containing the geometry of the election districts. This feature layer must use district identifiers (precincts ID, county name, and so on) as the primary key in a one-to-many relationship with a table layer of candidate results. If fields are provided, this layer may also include the total winning party and the number of ballots cast in each district. This parameter is required for ArcGIS Online and Portal for ArcGIS services. String
Table Layer URL (table_url) (Optional) REST endpoint of a table layer (including layer index value) containing the results for each candidate in each district. This table layer must use district identifiers as the foreign key in a one-to-many relationship with a feature layer containing the geometry of the districts. This layer should contain fields for the district identifier, the candidate names, and the number of ballots cast for each candidate. Fields may also be provided for the vote percentage received by each candidate and each candidate party affiliation. This parameter is required for ArcGIS Online and Portal for ArcGIS services. String
Feature Class (feature_class) Optional) Path to a feature class containing the geometry of the election districts. This feature class must use district identifiers as the primary key in a one-to-many relationship with a table of candidate results. If fields are provided, this feature class may also include the total winning party and the number of ballots cast in each district. This parameter is required for ArcGIS for Server or ArcGIS Enterprise services. Feature Class
Related Table (related_table) (Optional) Path to a table containing the results for each candidate in each district. This table must use district identifiers as the foreign key in a one to many relationship with a feature class containing the geometry of the districts. This table should contain fields for the district identifier, the candidate names, and the number of ballots cast for each candidate. Fields may also be provided for the vote percentage received by each candidate and each candidate party affiliation. This parameter is required for ArcGIS for Server or ArcGIS Enterprise services. Table
District ID Field - Feature Layer/Class (ft_precinct_fld) (Optional) String field in the feature layer (ArcGIS Online or Portal for ArcGIS) or feature class (ArcGIS for Server or ArcGIS Enterprise) containing the district identifiers. This field should also be the primary key in a one-to-many geodatabase relationship with the candidate table. This field must be populated for each feature before running the tool. String
Winning Party Field - Feature Layer/Class (ft_winner_fld) (Optional) Optional string field in the feature layer (ArcGIS Online or Portal for ArcGIS) or feature class (ArcGIS for Server or ArcGIS Enterprise) where the tool will record the winning party. This value will be based on the contents of the Winning Party Field in the spreadsheet. If no spreadsheet field was specified, this parameter will be unavailable. String
Number of Ballots Field - Feature Layer/Class (ft_ballots_fld) (Optional) Input spreadsheet fields containing the information for each candidate. Choose the field or fields containing candidate names and the number of votes received. Optionally, fields can also be specified for party affiliation and the percentage of the district vote received by each candidate. String
District ID Field - Table (tb_precincts_fld) (Optional) String field in the table layer (ArcGIS Online or Portal for ArcGIS) or related table (ArcGIS for Server or ArcGIS Enterprise) for the district identifiers. This field must also be the foreign key in a one-to-many geodatabase relationship with the district features. String
Candidate Name Field - Table (tb_name_fld) (Optional) String field in the table layer (ArcGIS Online or Portal for ArcGIS) or related table (ArcGIS for Server or ArcGIS Enterprise) where the tool will write the names of the candidates based on the values in the Candidate Name fields specified in the Candidate Fields parameter. String
Number of Votes Field - Table (tb_numvotes_fld) (Optional) Numeric field in the table layer (ArcGIS Online or Portal for ArcGIS) or related table (ArcGIS for Server or ArcGIS Enterprise) where the tool will write the number of votes received by each candidate based on the values in the Number of Votes fields specified in the Candidate Fields parameter. String
Party Field - Table (tb_party_fld) (Optional) Optional string field in the table layer (ArcGIS Online or Portal for ArcGIS) or related table (ArcGIS for Server or ArcGIS Enterprise) where the tool will write each candidate party affiliation based on the values in the Party fields specified in the Candidate Fields parameter. String
Percentage of Votes Field - Table (tb_percvotes_fld) (Optional) Optional numeric field in the table layer (ArcGIS Online or Portal for ArcGIS) or related table (ArcGIS for Server or ArcGIS Enterprise) where the tool will write the percentage of the districts votes received by each candidate based on the values in the Percentage of Vote fields specified in the Candidate Fields parameter. String
Top