Delete rows from matrix
6 visualizzazioni (ultimi 30 giorni)
Mostra commenti meno recenti
Mohamed Imbaby
il 9 Mag 2019
Modificato: madhan ravi
il 9 Mag 2019
Let's say we have matrix A=[1 2 3; 4 5 6; 7 8 9; 10 11 12], and b a number the user is inserting.
I want to delete 1st row if b=1, or delete the 2nd row if b=2 etc. Is this possible?
0 Commenti
Risposta accettata
madhan ravi
il 9 Mag 2019
Modificato: madhan ravi
il 9 Mag 2019
A=[ 1 2 3;...
4 5 6;...
7 8 9;...
10 11 12]
b=2;
A(b,:)=[]
0 Commenti
Più risposte (1)
Vedere anche
Categorie
Scopri di più su Resizing and Reshaping Matrices in Help Center e File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!