How to use logical indexing to change certain values in matrix

9 vues (au cours des 30 derniers jours)
Sam Grassie
Sam Grassie le 24 Nov 2015
Réponse apportée : dpb le 25 Nov 2015
I am trying to use logical indexing to change all elements=112 in a matrix into 225. How do I write a code for this. Any help hugely appreciated thanks in advance

Réponses (1)

dpb
dpb le 25 Nov 2015
x(x==112)=225;

Catégories

En savoir plus sur Matrix Indexing 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!

Translated by