how to delete repeated coordinates

1 次查看(过去 30 天)
muhammad ismat
muhammad ismat 2015-6-14
回答: dpb 2015-6-14
if i have d=[ 3 4; 4 3;7 6 ;6 7]
so i want this result d=[ 3 4; 7 6]

回答(1 个)

dpb
dpb 2015-6-14
Presuming values are significant but order isn't, simplest that comes to mind is
>> unique(sort(d,2),'rows')
ans =
3 4
6 7
>>

类别

Help CenterFile Exchange 中查找有关 Get Started with MATLAB 的更多信息

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by