title: Count occurrences of elements in a vector that occur in another vector
body: <p>I'm trying to count the occurrences of the elements in a vector that occur in another vector.</p>
  <pre><code>v1 &lt;- c(1,2,3)
  v2 &lt;- c(1,1,1,2,2,2)
  </code></pre>
  <p>How many times do 1,2,3 occur in v2?
  desired result <code>3,3,0</code></p>
  <p>This, <code>tabulate(match(v2, v1))</code>, returns</p>
  <pre><code>3,3
  </code></pre>