MATLAB Answers

How can I substitute all zeros of a matrix with minimum value of the same matrix?

1 view (last 30 days)
Et
Et on 3 Sep 2015
Commented: Rena Berman on 12 Oct 2020
How can I substitute all zeros of a matrix with minimum value of the same matrix?
  2 Comments

Sign in to comment.

Accepted Answer

Purushottama Rao
Purushottama Rao on 3 Sep 2015
 a(a==0)=min(a(a~=0))
  3 Comments

Sign in to comment.

More Answers (0)

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!