I have a large 2x2 matrix in which the date and temperature are included. I have NaN's cluster and incorrect data. Use the This is part of the catalog documentation You can remove rows and columns from the matrix by specifying the empty array [] of those rows or columns. Start with Then delete the second column of from the matrix A to You can also delete several rows / columns together: Find to obtain the index. These indexed are stored in other variables. How do I remove the rows related to the index (date and value)? Thank you.
large enough 2x2 matrix less or no understanding.
A = magic (4) a = 16 2 3 13 5 11 10 8 9 7 6 12 4 14 15 1
A (:, 2) = []
A = 16 3 13 5 10 8 9 6 12 4 15 1
A ([1 3], :) = [] A = 5 10 8 4 15 1
No comments:
Post a Comment