\begin{Schunk}
\begin{Sinput}
 library(rockchalk)
 dat$w5 <- combineLevels(dat$w2, levs = c("f", "j"), newLabel = c("fandj"))
\end{Sinput}
\begin{Soutput}
The original levels f g h i j 
have been replaced by g h i fandj 
\end{Soutput}
\begin{Sinput}
 table(dat$w5, dat$w2)
\end{Sinput}
\begin{Soutput}
         f  g  h  i  j
  g      0 14  0  0  0
  h      0  0  8  0  0
  i      0  0  0 13  0
  fandj  8  0  0  0  5
\end{Soutput}
\end{Schunk}
