User:Longestview/Excel

Compatible with up to 6 candidates. Columns:

Compatible with up to 6 candidates. Columns:

A: District number B: Candidate 1 C: Candidate 1 vote D: Candidate 1 pct. value (out of 1) Repeat for EFG,HIJ,KLM,NOP,QRS T: total votes cast Z1: primary runoff threshold (if applicable)

Primary table header

Candidates in '''boldface''' advanced to either the general election or the primary runoff. Candidates with an asterisk (*) won the first round of the primary outright.

{{Table alignment}}
{| class="wikitable sortable defaultcenter"
! rowspan="3" | District
! colspan=3 | (Nominee) OR (First place)
! colspan=6 | Runners-up
! colspan=3 | Total
|-

XXX

|-
! Candidate
! Votes
! %
! Candidate
! Votes
! %
! Candidate
! Votes
! %
! Votes
! {{abbr|Plr.|Plurality}}
! {{abbr|Mrg.|Margin}}
|-

FOR REPUBLICAN PRIMARIES:
! colspan=3 style="background-color:{{party color|Republican Party (US)}}" |
! colspan=6 style="background-color:#FF9955" |
! colspan=3 style="background-color:#000000" |

FOR DEMOCRATIC PRIMARIES:
! colspan=3 style="background-color:{{party color|Democratic Party (US)}}" |
! colspan=6 style="background-color:#51C2C2" |
! colspan=3 style="background-color:#000000" |

Single-round primaries

="| [[#District " & A2 & "|" & A2 & IF(AND(MOD(A2,100)>=11, MOD(A2,100)<=13), "th", CHOOSE(MIN(MOD(A2,10)+1, 5), "th", "st", "nd", "rd", "th")) & "]] || '''" & IF(B2="", "—", B2) & "''' || '''" & TEXT(C2, "#,##0") & "''' || '''" & TEXT(D2, "0.00%") & "''' || " & IF(E2="", "—", E2) & " || " & TEXT(F2, "#,##0") & " || " & TEXT(G2, "0.00%") & " || " & IF(K2="", IF(H2="", "—", H2), "''" & (COUNTA(H2,K2,N2,Q2)) & " others''{{efn|" & IF(H2<>"", H2 & ": " & TEXT(I2,"#,##0") & " votes, " & TEXT(J2,"0.00%"), "") & IF(K2<>"", "; " & K2 & ": " & TEXT(L2,"#,##0") & " votes, " & TEXT(M2,"0.00%"), "") & IF(N2<>"", "; " & N2 & ": " & TEXT(O2,"#,##0") & " votes, " & TEXT(P2,"0.00%"), "") & IF(Q2<>"", "; " & Q2 & ": " & TEXT(R2,"#,##0") & " votes, " & TEXT(S2,"0.00%"), "") & "}}") & " || " & IF(K2="", IF(OR(I2="", I2=0), "—", TEXT(I2, "#,##0")), "''" & TEXT(SUM(I2,L2,O2,R2), "#,##0") & "''") & " || " & IF(K2="", IF(OR(J2="", J2=0), "—", TEXT(J2, "0.00%")), "''" & TEXT(SUM(J2,M2,P2,S2), "0.00%") & "''") & " || " & TEXT(SUM(C2,F2,I2,L2,O2,R2), "#,##0") & " || " & TEXT(C2-F2, "+#,##0;-#,##0;0") & " || " & TEXT(D2-G2, "+0.00%;-0.00%;0.00%") & CHAR(10) & "|-"

Primary with runoffs

(Z1 should be set to 0.50, or whatever the threshold to avoid a runoff is.)

="| [[#District " & A2 & "|" & A2 & IF(AND(MOD(A2,100)>=11, MOD(A2,100)<=13), "th", CHOOSE(MIN(MOD(A2,10)+1, 5), "th", "st", "nd", "rd", "th")) & "]] || " & IF(D2<$Z$1, "'''" & IF(B2="", "—", B2) & "'''", "'''" & IF(B2="", "—", B2) & "*'''") & " || " & IF(D2<$Z$1, "'''" & TEXT(C2, "#,##0") & "'''", "'''" & TEXT(C2, "#,##0") & "'''") & " || " & IF(D2<$Z$1, "'''" & TEXT(D2, "0.00%") & "'''", "'''" & TEXT(D2, "0.00%") & "'''") & " || " & IF(D2<$Z$1, "'''" & IF(E2="", "—", E2) & "'''", IF(E2="", "—", E2)) & " || " & IF(D2<$Z$1, "'''" & TEXT(F2, "#,##0") & "'''", IF(OR(F2="", F2=0), "—", TEXT(F2, "#,##0"))) & " || " & IF(D2<$Z$1, "'''" & TEXT(G2, "0.00%") & "'''", IF(OR(G2="", G2=0), "—", TEXT(G2, "0.00%"))) & " || " & IF(K2="", IF(H2="", "—", H2), "''" & (COUNTA(H2,K2,N2,Q2)) & " others''{{efn|" & IF(H2<>"", H2 & ": " & TEXT(I2,"#,##0") & " votes, " & TEXT(J2,"0.00%"), "") & IF(K2<>"", "; " & K2 & ": " & TEXT(L2,"#,##0") & " votes, " & TEXT(M2,"0.00%"), "") & IF(N2<>"", "; " & N2 & ": " & TEXT(O2,"#,##0") & " votes, " & TEXT(P2,"0.00%"), "") & IF(Q2<>"", "; " & Q2 & ": " & TEXT(R2,"#,##0") & " votes, " & TEXT(S2,"0.00%"), "") & "}}") & " || " & IF(K2="", IF(OR(I2="", I2=0), "—", TEXT(I2, "#,##0")), "''" & TEXT(SUM(I2,L2,O2,R2), "#,##0") & "''") & " || " & IF(K2="", IF(OR(J2="", J2=0), "—", TEXT(J2, "0.00%")), "''" & TEXT(SUM(J2,M2,P2,S2), "0.00%") & "''") & " || " & TEXT(SUM(C2,F2,I2,L2,O2,R2), "#,##0") & " || " & TEXT(C2-F2, "+#,##0;-#,##0;0") & " || " & TEXT(D2-G2, "+0.00%;-0.00%;0.00%") & CHAR(10) & "|-"

General election header (2-party)

{{Table alignment}}
{| class="wikitable sortable defaultcenter"
! rowspan="3" | District
! colspan=3 | [[Democratic Party (US)|Democrats]]
! colspan=3 | [[Republican Party (US)|Republicans]]
! colspan=3 | Total
|-
! colspan=3 style="background-color:{{party color|Democratic Party (US)}}" |
! colspan=3 style="background-color:{{party color|Republican Party (US)}}" |
! colspan=3 style="background-color:#000000" |
|-
! Candidate
! Votes
! %
! Candidate
! Votes
! %
! Votes
! {{abbr|Plr.|Plurality}}
! {{abbr|Mrg.|Margin}}
|-

General election header (multi-party)

{{Table alignment}}
{| class="wikitable sortable defaultcenter"
! rowspan="3" | District
! colspan=3 | [[Democratic Party (US)|Democrats]]
! colspan=3 | [[Republican Party (US)|Republicans]]
! colspan=3 | Third-party and independent candidates
! colspan=3 | Total
|-
! colspan=3 style="background-color:{{party color|Democratic Party (US)}}" |
! colspan=3 style="background-color:{{party color|Republican Party (US)}}" |
! colspan=3 style="background-color:{{party color|Independent Party (US)}}" |
! colspan=3 style="background-color:#000000" |
|-
! Candidate
! Votes
! %
! Candidate
! Votes
! %
! Candidate
! Votes
! %
! Votes
! {{abbr|Plr.|Plurality}}
! {{abbr|Mrg.|Margin}}
|-

For third-party candidates:
([[Write-in candidate|write-in]])
([[Independent politician|Ind.]])
([[Libertarian Party (US)|Lbt.]])
([[Constitution Party (US)|Cst.]])
([[Green Party (US)|Grn.]])
([[Mountain Party|Mtn.]])
([[Working Families Party|WFP]])
([[Vermont Progressive Party|Prg.]])
([[Forward Party (United States)|Fwd.]])
([[American Solidarity Party|Sol.]])
([[Communist Party USA|Comm.]])
([[Alliance Party (United States)|All.]])
([[No Labels|NoL]])
([[Legal Marijuana Now Party|LMN]])
([[Approval Voting Party|Apv.]])
([[Liberal Party|LPU]])
([[Natural Law Party|NLP]])
([[Party for Socialism and Liberation|PSL]])
([[Natural Law Party|NLP]])
([[Unity Party of America|Uni.]])

General election header (multi-party with scattering)

{{Table alignment}}
{| class="wikitable sortable defaultcenter"
! rowspan="3" | District
! colspan=3 | [[Democratic Party (US)|Democrats]]
! colspan=3 | [[Republican Party (US)|Republicans]]
! colspan=3 | Third-party and independent candidates
! colspan=2 | [[Write-in candidate|Scattering]]
! colspan=3 | Total
|-
! colspan=3 style="background-color:{{party color|Democratic Party (US)}}" |
! colspan=3 style="background-color:{{party color|Republican Party (US)}}" |
! colspan=3 style="background-color:{{party color|Independent Party (US)}}" |
! colspan=2 style="background-color:#ffffff" |
! colspan=3 style="background-color:#000000" |
|-
! Candidate
! Votes
! %
! Candidate
! Votes
! %
! Candidate
! Votes
! %
! Votes
! %
! Votes
! {{abbr|Plr.|Plurality}}
! {{abbr|Mrg.|Margin}}
|-

Content Disclaimer

Informasi ini disarikan dari Wikipedia dan disajikan kembali untuk tujuan edukasi. Konten tersedia di bawah lisensi CC BY-SA 3.0. Kami tidak bertanggung jawab atas ketidakakuratan data yang bersumber dari kontribusi publik tersebut.

  1. The information displayed on this website is sourced in part or in whole from Wikipedia and has been adapted for the purpose of restating it. We strive to provide accurate and relevant information, however:
  2. There is no guarantee of absolute accuracy. Wikipedia is an open, collaborative project that can be edited by anyone, so information is subject to change.
  3. It is not intended to constitute professional advice. The content displayed is for informational and educational purposes only. For important decisions (e.g., medical, legal, or financial), please consult a professional.
  4. Content copyright. Wikipedia is licensed under the Creative Commons Attribution-ShareAlike License (CC BY-SA). This means that content may be reused with appropriate attribution and shared under a similar license.
  5. Responsible use. Any risk arising from the use of information from this website is entirely the responsibility of the user.