How to create a limited frequent values in array?
显示 更早的评论
Is there anyone know how to create limited frequent values in array? Because, what I found is only the most frequent. I'd like to make it like two or three times appear. For example this problem :
Return a list of all values (sorted smallest to largest) that appear exactly three times in the input vector x. So
if
x = [1 2 5 2 2 7 8 3 3 1 3 8 8 8]
then
y = [2 3]
采纳的回答
更多回答(1 个)
Zaki
2013-9-27
0 个投票
1 个评论
Wayne King
2013-9-27
Can you accept the answer if it answered your question?
类别
在 帮助中心 和 File Exchange 中查找有关 MATLAB 的更多信息
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!