replacing components of a matrix
2 visualizaciones (últimos 30 días)
Mostrar comentarios más antiguos
how to generate a matrix that replaces all components of a previous matrix lying between 2.9 and 3.2, by -1?
0 comentarios
Respuesta aceptada
Matt Kindig
el 8 de Mayo de 2013
%your matrix is M
isBetween = (M >= 2.9) & (M <= 3.2);
M(isBetween) = -1
Más respuestas (0)
Ver también
Categorías
Más información sobre Matrices and Arrays en Help Center y File Exchange.
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!