|
From: | Carlo de Falco |
Subject: | Re: combinations |
Date: | Sun, 31 May 2009 21:24:01 +0200 |
On 31 May 2009, at 20:30, Carlo Rossi wrote:
Hello, given A = [1; 2; 3] I need a vector of combination without repetition like this: (1,2), (1,3), (2,3) is there any matlab function? I didn't find it! thanks,
try A = [1; 2; 3]; unique(sort (perms (A)(:,[1 2]), 2), 'rows') HTH, c.
[Prev in Thread] | Current Thread | [Next in Thread] |