title: model.matrix(): why do I lose control of contrast in this case
body: <p>Suppose we have a toy data frame:</p>
  
  <pre><code>x &lt;- data.frame(x1 = gl(3, 2, labels = letters[1:3]),
                  x2 = gl(3, 2, labels = LETTERS[1:3]))
  </code></pre>
  
  <p>I would like to construct a model matrix</p>
  
  <pre><code>#    x1b x1c x2B x2C
  # 1    0   0   0   0
  # 2    0   0   0   0
  # 3    1   0   1   0
  # 4    1   0   1   0
  # 5    0   1   0   1
  # 6    0   1   0   1
  </code></pre>
  
  <p>by:</p>
  
  <pre><code>model.matrix(~ x1 + x2 - 1, data = x,
               contrasts.arg = list(x1 = contr.treatment(letters[1:3]),
                                    x2 = contr.treatment(LETTERS[1:3])))
  </code></pre>
  
  <p>but actually I get:</p>
  
  <pre><code>#   x1a x1b x1c x2B x2C
  # 1   1   0   0   0   0
  # 2   1   0   0   0   0
  # 3   0   1   0   1   0
  # 4   0   1   0   1   0
  # 5   0   0   1   0   1
  # 6   0   0   1   0   1
  # attr(,"assign")
  # [1] 1 1 1 2 2
  # attr(,"contrasts")
  # attr(,"contrasts")$x1
  #   b c
  # a 0 0
  # b 1 0
  # c 0 1
  
  # attr(,"contrasts")$x2
  #   B C
  # A 0 0
  # B 1 0
  # C 0 1
  </code></pre>
  
  <p>I am sort of confused here:</p>
  
  <ul>
  <li>I have passed in explicit contrast matrix to drop first factor levels;</li>
  <li>I have asked for dropping intercept.</li>
  </ul>
  
  <p>Then why am I getting a model matrix with 5 columns? How can I get the model matrix I want?</p>