replace duplicate entry in columns
显示 更早的评论
if i have this matrix
2 6 5 1 3 3
3 8 2 3 5 6
6 3 1 4 2 6
4 6 6 4 3 4
I want to check for duplicate entries in each column, if there is an duplicate, i want to replace it with any random entry from the row where the duplicate is located. If no unique number can be found, replace it with 0. for example, column 4 has duplicate 4's in row 3 and 4, i want replace one with any other unidue number from the row. In this case, the only other unique number from row 4 is 6 because there is a 3 in column 4
采纳的回答
更多回答(0 个)
类别
在 帮助中心 和 File Exchange 中查找有关 Library Development 的更多信息
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!