How can I delete rows from matrix in matlab?
1 vue (au cours des 30 derniers jours)
Afficher commentaires plus anciens
ghazwan alsoufi
le 15 Jan 2015
Réponse apportée : Mohammad Abouali
le 15 Jan 2015
Hello there, I have a linear programming problem as you Know with two matrices left hand side and right hand side. I want to delete the rows from two matrices which are associated with the value zero (0) in the right hand side. Regards, Ghazwan
0 commentaires
Réponse acceptée
Mohammad Abouali
le 15 Jan 2015
Let's say you want to delete the r-th row from matrix A. This should work:
A=A([1:r-1 r+1:end],:)
0 commentaires
Plus de réponses (0)
Voir également
Catégories
En savoir plus sur Creating and Concatenating Matrices dans Help Center et File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!