Tuesday, July 22, 2008

 

4Pres


Monday, February 11, 2008

 

Post the Nineteenth

Wherein Your Host Wonders How Liberal McCain Is...

Your host has been interested in the conservative reaction against John McCain (and to a lesser extent Mike Huckabee). Rush Limbaugh, for example, recently opined that a McCain or Huckabee presidency would “destroy” the GOP. Ann Coulter has said she would support Clinton over the Arizona Senator and James Dobson stated McCain has neither the conservative credentials nor the temperament to be president!

Why are conservatives so uncomfortable with McCain?

I think that these reservations are brought about because many conservatives have bought into media hype about John McCain being a liberal Republican maverick. I have long said to anyone who will listen that, “McCain is much more conservative than the media give him credit for being.” Being a “moderate-liberal” in media portrayals both helps and hurts candidate McCain. This image as a maverick appeals to moderates and liberals BUT the same portrait also turns off the conservative base.

What I want to suggest is that John McCain may not be as much of a centrist-liberal maverick as is commonly thought. Overall his voting record is very much within the Republican mainstream. We could call him the “average Republican.” One important thing to remember is that the Republican Party is significantly to the right of the average American voter. So, in being an “average Republican,” McCain is fairly conservative compared to the population at large. Compared to members of his own Party, McCain is not especially conservative, but he neither is he especially liberal. The Arizona senator’s voting record is really in the middle of the conservative movement. When talk show hosts and conservative activists complain that McCain is not conservative enough they are either comparing him to a far-right ideal or don’t understand how conservative he is.

If I am right, then this image of McCain as a liberal maverick is more the product of a few high-profile stands and media hype but not the result of day-in-day-out differences with other conservatives. As such, liberals might want to think twice before voting for him and conservatives might want to re-examine some of their discomfort.

To prove this I will use two Congressional scorecards. The American Conservative Union (ACU) is a conservative group that produces a scorecard ranking senators from most to least conservative on a one-hundred point scale. The group Americans for Democratic Action (ADA) does the same thing for liberalism. According to the ACU lifetime scores, John McCain is the 39th most conservative member of the 2006 Senate. He is the 17th most liberal Republican out of the 55 Republican Senators. According to the ADA, McCain is the 45th most conservative member of the Senate and is tied for the 11th most liberal Republican (with Lugar and Murkowski) in the 109th Congress. (The ADA lifetime scores were not updates past 2000 so I averaged the scores for 2006 and 2005 to create these scores. McCain’s “lifetime liberalism” score from the ADA is 9 out of 100 but his 2006-2005 average was 12.5.)

These numbers can make it sound like McCain is in the liberal wing of his party. Using these rankings, he certainly seems closer to the liberal end of the Republican spectrum than he is to the conservative end. One thing that is easy to miss in just talking about rankings is that there is a very small margin between members of the same party on these scorecards. We can use the ADA scores to say that 44 Senators are more conservative than McCain and only 10 Republicans are more liberal, but the distance between John McCain and the conservatives is much smaller than the distance between him and the liberals. The ADA scorecard is based on 20 votes per year. So changing McCain’s vote on only four of the forty bills (see my note above on how I calculated ADA scores) would tie him for the most conservative senator! Conversely, he’d have to change his vote on thirty-four out of forty bills to tie the most liberal senator. So only a few votes each year separate McCain from the most conservative members of his own party. Members of the Senate take literally hundreds of votes every year and the handful that separate McCain from his more conservative colleagues must border on insignificance.

Another way of looking at this is by using standard deviation. The average ACU score for all Republicans in the 2006 Senate was 84.5. (Removing Chaffee, Spector, Snow and Collins the average is 87.5.) The standard deviation for 2006 Senate Republicans is 13.4 (and 7.8 with Chaffee, Spector, Snow and Collins removed). This means from 71.1 to 97.9 (84.5+/-13.4) is considered “average” for Republicans. With the outliers (Chaffee, Spector, Snow and Collins) removed, the range from 76.7 to 92.3 (84.5+/-7.8) is considered “average.” A Republican must have a score lower than 71.1 (or 76.7 if we want to consider the four liberals “non-Republicans”) to be “more liberal than the average Republican Senator.” A Republican would have to have a score higher than 97.9 (or 92.3 using the stricter measure) to be considered “more conservative than the average Republican Senator.” McCain’s lifetime score was 82.3. Under neither scenario (with or without the Northeast Republicans) could he be considered “more liberal” than the average Republican Senator. His voting record is about average for a Republican in the Senate.

Scatterplots are also useful in establishing this point. The following two scatterplots plot the ADA (liberal) score on the X-Axis and the ACU (conservative) score on the Y-Axis. The first graph is for all members of the Senate in 2006 and the second is for only Republicans.



As we can see from the above graph, there are two large “clumps” of Senators: one on the upper left representing the Republicans and the other on the bottom right representing the Democrats. We can see that McCain is close to the largest clump of Republican senators and very near the marker “REPAVERAGE” which equals the average Republican score.

The following scatterplot has the Senate Democrats removed so we can see the Republicans more clearly. Again, note how close McCain is to “REPAVERAGE”…



John McCain is not a liberal Republican. While his maverick reputation may or may not be well-deserved (he has bucked the party leadership from time-to-time), the “liberal” label must almost certainly be rejected. On some high-profile issues he may have disappointed party activists, but on many more issues (represented by the scorecard results) he was right in line with what Republicans expect from their candidates. We cannot say that John McCain is significantly more liberal (or conservative) than the Republican mainsteam. He may be a moderate maverick but he is no liberal in sheep’s clothing.

Labels:


Thursday, July 13, 2006

 

Post the Eighteenth

Wherein your Host Announces that Phase II is Almost Complete

Life Plan
Phase I: Graduate School
Phase II: ICPSR
Phase III: ????
Phase IV: PROFIT

Only a week and some change left, I'm coming home soon everyone!

Labels:


Monday, July 10, 2006

 

Post the Seventeenth

Wherein your Host Praises the Gamma Distribution

Your host is a stupid man. But he is a stupid man who recently discovered one of his own mistakes and so is feeling pretty good right now!

I have a project that I’ve been working on for a year or more now and it just isn't going anywhere. I think the underlying ideas are interesting and important but the analysis wasn't holding up to statistical scrutiny.

One of the problems I have had with quantitative methods is learning to think statistically. This is hard to do when there is just so much out there that I simply haven’t learned yet. How could I think of framing a research question on differences in variation across some category when I didn’t know that heteroscedastic regression existed? How could I come up with a topic that examines different effects across various levels an observation is nested in when I didn’t know about hierarchical models?

It is also hard for me to think statistically because, as I have related previously I am math phobic. So today in class we were covering Generalized Linear Models. This is something a very able professor at UVA had attempted to teach me previously but we only covered the binomial and Poisson distributions. She had informed us that other probability distributions were available for analysis but, in my math-stupidity, I didn’t fully grasp what this meant.

Now I have discovered the glorious gamma distribution which far better fits my data than the normal, binomial or Poisson distributions. I get it now!

This:

Looks more like this (the red line):


Than it does like any of these:


After very quickly running some new analyses, it appears that, indeed, my hypothesized relationships do hold up to scrutiny (given a gamma distribution) and I might have a good conference paper (cross my fingers and pray it is publishable) on my hands now.

Oh the things one learns at math camp! Angels, saints, ministers of grace and methodologists pray for the humble student Nathan of modest mind who tries so hard yet has so far to go.

Credo ut intelligam.

Labels:


 

Post the Sixteenth

Wherein your Host Displays "Non-Quantitative" Tables

Today in class, a professor referred to "quantitative tables” – certainly a redundancy which he recognized – but it made me wonder what “non-quantitative tables” would look like...

... so I made up two sample "non-quantitative" tables for the qualitative methods folks and historians to use. Knock yourselves out guys:

Labels: ,


Thursday, July 06, 2006

 

Post the Fifteenth

Wherein your Host Proposes a Research Topic

Someone should look into this. Seriously.



... although I think their causal arrows are mixed up: it seems more likley that global warming is destroying delicate pirate habitats rather than a decrease in pirates is causing global warming. Maybe I'll use my new R skillz to investigate further...

Labels:


 

Post the Fourteenth

Wherein your Host Demonstrates Why R is Superior to STATA

To run a heteroskedastic regression in STATA where the independent variable is the vote gap between Republican and Democratic candidates (votegap) and the dependent variables are the partisan polls of the two major party candidates (dempoll, reppoll), the gap between these two polls (pollgap), dummy variables showing whether an incumbent is running (deminc, repinc) and we wanted to see if variance changed by days before the election (days2go) and depending on who was conducting the poll (dempoll, repopll) we would type:

ml model lf hetreg (slopes:votegap=dempoll reppoll pollgap deminc repinc) (variance: days2go dempoll reppoll)

-----------------------------------------------------------------------------------------------

In R, to run the same model, we would type:

hetreg<-function(y,X,Z,method=’BFGS’,Xnames=colnames(X),Znames=colnames(Z)) X<-cbind(1,X) colnames(X)[1]<-“Constant” nx<-ncol(X) Z<-cbind(1,Z) colnames(Z)[1]<-“Z Constant” nz<-ncol(Z)

negln<-function(theta,X,Z,y){
b<-theta[1:ncol(x)]
g<-theta[ncol(X)+1:ncol(Z)] lnl<-as.vector(-.5*(Z%*%g)-(.5/exp(Z%*%g))*(y-X%*%b)^2) -sum(ln)}

result<-c(optim(c(mean(y),rep(0,ncol(X)-1),log(var(y)),
rep(0,ncol(Z=neglnl, hessian=T, method=method, X=X, Z=Z, y=y),
list(varnames=c(Xnames,Znames),nx=nx,nz=nz))
class(result)<-“hatreg” return(result)

print.hetreg<-function(object{
coef<-object$par
names(coef)<-object$varnames print(coef)
if(object$convergence==0) cat(‘\n hetreg converged\n’)
if(!object$convergence==0) cat(‘n\ *** hetreg failed to converge *** \n’) invisible(object)}

summary.hetreg<-function(object, cover=FALSE){
coef<-object$par names(coef)<-object$varnames
nx<-object$nx nz<-object$nz
maxl<-object$value
vc<-solve(object$hessian)
colnames(vc)<-names(coef)
rownames(vc)<-names(coef)
se<-sqrt(diag(vc))
zscore<-coef/se
pz<- pnorm*-2(-abs(coef/se))
dn<-c(“Estimate”, “Std.Error”)
coef.table<-cbind(coef,se,zscore,pz) dimnames(coef.table)<-list(names(coef),c(dn,”z-value”, “Pr(>|z|)”))}

cat(“\n Heteroskedastic Linear Regression by Nathan A. Jones, Esq. of the Mad R Skillz \n”)
cat(“\n Estimated Parameters \n”)
print(coef.table)
cat(“\n Log-Likelihood: “,-object$value, “\n”)

if(cover{
cat(“\n Variance-Covariance Matrix for Parameters \n”
print(vc)}

ghat<-coef[(nx+2):length(coef)]
gvc<-vc[(nx+2):length(coef),(nx+2):length(coef)] wald<-t(ghat)%*%solve(gvc)%*%ghat
pwald<- -1-pchisq(wald,nz-1)
cat(“\n Wald Statistic: “,wald,”with”, nz-1, “degrees of freedom\n”) cat(“ p=”,pwald,”\n”)}

hregl<-hetreg(votegap,cbind(dempoll,reppoll,deminc,repinc,pollgap), cbind(days2go,dempoll,reppoll))

summary(hreg1)

-----------------------------------------------------------------------------------------------

The question here is: why code myself in R when someone far smarter than I am (Charles Franklin) has already coded the same formula in STATA for me?

One obvious answer is that by coding myself (see above), I can make the printout say "Heteroskedastic Linear Regression by Nathan A. Jones, Esq. of the Mad R Skillz" at the top of my computer screen. That, in and of itself, must be worth SOMETHING because the STATA print out just says "Results." Bo-RING.

I think I can see now why R is so much better than STATA.

Labels:


This page is powered by Blogger. Isn't yours?