I need a function to identify if a number is part of a vector or matrix.
9 views (last 30 days)
Show older comments
Clodoaldo de Souza Faria Júnior
on 21 Sep 2021
Commented: Clodoaldo de Souza Faria Júnior
on 21 Sep 2021
I don't need to know the number or position, I just need to know if a number belongs to a vector or matrix.I use the ismember function, but it is very slow when I repeat this many times, I would like an alternative.
The only consideration is that it has to be a function or quick code.
0 Comments
Accepted Answer
More Answers (1)
Jan
on 21 Sep 2021
If this is really time critical try https://www.mathworks.com/matlabcentral/fileexchange/26867-anyeq
See Also
Categories
Find more on Resizing and Reshaping Matrices in Help Center and File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!