title: List all possible combinations for a vector
body: <p>So say I have a vector <code>[1 0]</code>, I want to list all the possible combinations of the numbers in that vector that fit into a <code>1x3</code> vector. i.e.
  <code>[1 1 1] [1 1 0] [1 0 0] [0 0 0] [0 0 1] [0 1 1] [1 0 1] [0 1 0]</code>.</p>
  
  <p>I have done this (here is the <a href="http://pastebin.com/feWn9sts" rel="nofollow">link</a>), but my function is very slow when I go to do things in the 10th dimension.
  That is when I run <code>combos([1 0],10)</code>, it takes a few minutes to do.</p>
  
  <p>I was wondering if matlab had basically a function that already do that (similar to <code>perms</code> or <code>nchoosek</code>), or if someone has a faster method than what I did.</p>