Is there a way to determine 2012 presidential margin for a city on DRA?
       |           

Welcome, Guest. Please login or register.
Did you miss your activation email?
October 27, 2021, 08:35:15 PM

  Talk Elections
  About this Site
  The Atlas
  Is there a way to determine 2012 presidential margin for a city on DRA?
« previous next »
Pages: [1]
Author Topic: Is there a way to determine 2012 presidential margin for a city on DRA?  (Read 455 times)
erwint.2021
Jr. Member
***
Posts: 313
United States


Show only this user's posts in this thread
« on: July 22, 2021, 11:31:04 PM »

Is there a way to determine 2012 presidential margin for a city on DRA for Texas by using PVI President 2012/2016 or Composite 2012-2016?
Logged
Chap Petersen Democrat
lfromnj
Atlas Politician
Atlas Icon
*****
Posts: 14,413


Show only this user's posts in this thread
« Reply #1 on: July 23, 2021, 10:50:23 AM »

Is there a way to determine 2012 presidential margin for a city on DRA for Texas by using PVI President 2012/2016 or Composite 2012-2016?

Yeah use PVI and reverse that
Here's a python code that just requires raw vote or percentage for 2016
Quote
country = 48.2/(46.1+48.2)
country2012=51.1/(47.2+51.1)
C2016 = float(input("Input 2016 Clinton raw Votes or Percentage"))
T2016= float(input("Input 2016 Trump raw votes or Percentage"))
PV = float(input("Give PVI value 2012/2016 negative if R"))
PVI = PV/100
p2016= C2016/(C2016+T2016)
PVI2016=p2016-country
PVI2012 =2*PVI-PVI2016
Obama= PVI2012+country2012
print ("Obama share is",Obama*100)
print ("Romney share is",(1-Obama)*100)
Logged
erwint.2021
Jr. Member
***
Posts: 313
United States


Show only this user's posts in this thread
« Reply #2 on: July 23, 2021, 10:55:38 AM »

Is there a way to determine 2012 presidential margin for a city on DRA for Texas by using PVI President 2012/2016 or Composite 2012-2016?

Yeah use PVI and reverse that
Here's a python code that just requires raw vote or percentage for 2016
Quote
country = 48.2/(46.1+48.2)
country2012=51.1/(47.2+51.1)
C2016 = float(input("Input 2016 Clinton raw Votes or Percentage"))
T2016= float(input("Input 2016 Trump raw votes or Percentage"))
PV = float(input("Give PVI value 2012/2016 negative if R"))
PVI = PV/100
p2016= C2016/(C2016+T2016)
PVI2016=p2016-country
PVI2012 =2*PVI-PVI2016
Obama= PVI2012+country2012
print ("Obama share is",Obama*100)
print ("Romney share is",(1-Obama)*100)

Thank you so much. I was thinking there was a way via PVI, although it seems that there is something off about the percentages on DRA. In 2016, the Dem % was off by over 1% in Dallas Co.
Logged
Pages: [1]  
« previous next »
Jump to:  


Login with username, password and session length

Terms of Service - DMCA Agent and Policy - Privacy Policy and Cookies

Powered by SMF 1.1.21 | SMF © 2015, Simple Machines

Page created in 0.177 seconds with 13 queries.