Delete rows from array

3 次查看(过去 30 天)
I have an array called yi1
It has more than 10,000 rows.
How can I delete all rows from 10,000 upwards?

采纳的回答

James Tursa
James Tursa 2016-2-2
yi1 = your matrix
yi1(10000:end,:) = [];

更多回答(1 个)

Image Analyst
Image Analyst 2016-2-5
Another way. Assuming a 2D array:
yi1 = yi1(1:9999,:); % Extract first 9,999 rows

类别

Help CenterFile Exchange 中查找有关 Multidimensional Arrays 的更多信息

标签

尚未输入任何标签。

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by