add_wi: Add "other" and write in votes

View source: R/format_values.R

add_wiR Documentation

Add "other" and write in votes

Description

For a given office, looks at office_vote (the candidate in characters) and the office_party (the party, -1, 1, or otherwise 0), and edits the 0 to 0.5 if office_party is 0 but candiddate name is not NA (a third party or write-in)

Usage

add_wi(tbl, var)

Arguments

tbl

wide table

var

the unquoted office variable


kuriwaki/ballot documentation built on May 1, 2023, 9:55 p.m.