Could anyone help me to solve on unused_rows=1:50

3 views (last 30 days)
In my code i am using
unused_rows = 1:50
But when the command executes, it displays the result as shown in the attached image.
Actually it should display 1x50 double. Could anyone help me to solve this?
  2 Comments
ANKUR KUMAR
ANKUR KUMAR on 8 Jan 2018
Edited: ANKUR KUMAR on 8 Jan 2018
I am getting the correct answer. Just one line code and it will give the sequence up to 50. If your problem is not yet resolved, then clear all the variables and then run the code.

Sign in to comment.

Answers (1)

Rik
Rik on 8 Jan 2018
If you look at the code in my answer, you will see that the vector unused_rows decreases in size every iteration. It is initialized based on m. If you change m, this vector will change as well. You can adapt my code to support a different number of rows by using unused_rows=1:size(B,1); instead.

Categories

Find more on Neuroimaging in Help Center and File Exchange

Community Treasure Hunt

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

Start Hunting!