Remove data from matrix
2 views (last 30 days)
Show older comments
How i remove the data >30 and <25 ? and how i make a pattern to remove them in any futuer data ?
4 Comments
KALYAN ACHARJYA
on 6 Apr 2020
Edited: KALYAN ACHARJYA
on 6 Apr 2020
When you remove the element from the matrix, what remains in that location?
Accepted Answer
KSSV
on 6 Apr 2020
If A is your array....
You can remove data using:
A(A>30) = [] ;
A(A<25) = [] ;
Or replace them with NaN's, if yu want same size.
A(A>30) = NaN ;
A(A<25) = NaN ;
0 Comments
More Answers (0)
See Also
Categories
Find more on Multidimensional Arrays in Help Center and File Exchange
Products
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!