title: Want to use a vector as parameter to a function, without having to separate its elements
body: <p>If I call a matlab function with:
   <strong><em>func(1,2,3,4,5)</em></strong>
  it works perfectly.</p>
  
  <p>But if I do:
   <strong><em>a=[1,2,3,4,5]</em></strong>  %(a[1;2;3;4;5] gives same result)</p>
  
  <p>then:</p>
  
  <p><strong><em>func(a)</em></strong></p>
  
  <p>gives me:</p>
  
  <p><em>??? Error ==> func at 11
   Not enough input arguments.</em></p>
  
  <p>Line 11 in func.m is:</p>
  
  <p><strong><em>error(nargchk(5, 6, nargin));</em></strong></p>
  
  <p>I notice that this works perfectly:</p>
  
  <p><strong><em>func(a(1),a(2),a(3),a(4),a(5))</em></strong></p>
  
  <p>How can I use the vector 'a' as a parameter to a function? I have another function otherfunc(b) which returns a, and would like to use its output as a paramater like this <strong><em>func(otherfunc(b))</em></strong>.</p>