Info

此问题已关闭。 请重新打开它进行编辑或回答。

suppose i have a matrix [1.22 0 2.33 3.444 1.222 0] and i want the solution to be the number of iterations between non zero values. the solution should be [1 2 1 1]

1 次查看(过去 30 天)
Z(xidx) = z;
this is the vector that i have.
  1 个评论
Star Strider
Star Strider 2017-3-19
Your vector has 6 elements and your ‘solution’ has 4.
What procedure do you use for getting the ‘solution’? What ‘rule’ do you use?

回答(0 个)

此问题已关闭。

标签

产品

Community Treasure Hunt

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

Start Hunting!

Translated by