emp.x=[]; emp.info=[];emp.fit=[]; pop=repmat(emp,1,1);pop(1).x=[1 2 3 4];pop(2).x=[3 2 1 4];pop(3).x=[1 2 3 4];pop(4).x=[2 1 3 4];
How to make the above structure (pop) unique?
The result would be like the following figure.
unique struct
emp.x=[]; emp.info=[];emp.fit=[]; pop=repmat(emp,1,1);pop(1).x=[1 2 3 4];pop(2).x=[3 2 1 4];pop(3).x=[1 2 3 4];pop(4).x=[2 1 3 4];
Best Answer