Delete rows from a matrix

3 views (last 30 days)
Eranja Noopehewa
Eranja Noopehewa on 25 Mar 2020
Commented: Ameer Hamza on 25 Mar 2020
Hi, I want to delete 1:5 and 10:15 rows from a given 15*1 matrix. How can I do this ?

Accepted Answer

Ameer Hamza
Ameer Hamza on 25 Mar 2020
Edited: Ameer Hamza on 25 Mar 2020
Something like this
x = (1:15)';
x([1:5 10:15], :) = [];

More Answers (0)

Categories

Find more on Creating and Concatenating 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!