Delete zero values in works pace variable

1 次查看(过去 30 天)
Hi, How to delete zero values in the workspace variable and save the updated value (without zero) into another variable?
Great Thanks

采纳的回答

Julia
Julia 2014-7-23
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

更多回答(0 个)

类别

Help CenterFile Exchange 中查找有关 NaNs 的更多信息

Community Treasure Hunt

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

Start Hunting!

Translated by