How can I remove zero values from the followning label matrix?.
1 visualización (últimos 30 días)
Mostrar comentarios más antiguos
moon sun
el 22 de Sept. de 2014
Comentada: moon sun
el 22 de Sept. de 2014
How can I remove zero values form the following

?.
0 comentarios
Respuesta aceptada
Hikaru
el 22 de Sept. de 2014
If your matrix is A, then
A(A==0) = []
will remove the zeros. But it will change the matrix into a vector.
If you want to keep the matrix in the same shape, maybe
A(A==0) = NaN
2 comentarios
Más respuestas (0)
Ver también
Categorías
Más información sobre Logical 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!