Delete zero values in works pace variable

1 Ansicht (letzte 30 Tage)
missC
missC am 23 Jul. 2014
Kommentiert: missC am 23 Jul. 2014
Hi, How to delete zero values in the workspace variable and save the updated value (without zero) into another variable?
Great Thanks

Akzeptierte Antwort

Julia
Julia am 23 Jul. 2014
a=[1 2 3 0 4 5 0 6 7]
a =
1 2 3 0 4 5 0 6 7
>> a=a(a>0)
a =
1 2 3 4 5 6 7

Weitere Antworten (0)

Kategorien

Mehr zu MATLAB finden Sie in Help Center und File Exchange

Community Treasure Hunt

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

Start Hunting!

Translated by