\begin{Schunk}
\begin{Sinput}
 lnth <- length(nes2002$V023022) 
 newdfD1 <-data.frame(V023022=seq(1,7), repub=0, democ=1)
 newdfD1
\end{Sinput}
\begin{Soutput}
  V023022 repub democ
1       1     0     1
2       2     0     1
3       3     0     1
4       4     0     1
5       5     0     1
6       6     0     1
7       7     0     1
\end{Soutput}
\begin{Sinput}
 predvalsD1 <- predict(bushideoglm2, newdata=newdfD1, type="response")
 newdfR1 <-data.frame(V023022=seq(1,7), repub=1, democ=0)
 newdfR1
\end{Sinput}
\begin{Soutput}
  V023022 repub democ
1       1     1     0
2       2     1     0
3       3     1     0
4       4     1     0
5       5     1     0
6       6     1     0
7       7     1     0
\end{Soutput}
\begin{Sinput}
 predvalsR1 <- predict(bushideoglm2, newdata=newdfR1, type="response")
 newdfI1 <-data.frame(V023022=seq(1,7), repub=0, democ=0)
 predvalsI1 <- predict(bushideoglm2, newdata=newdfI1, type="response")
\end{Sinput}
\end{Schunk}
