0

How can I adjust the boundary double array that looks like that:

102     8
101     9
100     9
99      9
…       …

To be a double array that looks like this:

102   8   101   9   100   9   99   9 … …

Code:

I = imread('coins.png');
BW = im2bw(I, graythresh(I));
[B,L] = bwboundaries(BW,'noholes');
boundary = B{1}
elyraz
  • 473
  • 5
  • 18

1 Answers1

0
% consider A is your matrix.
At=A.';
At(:)  % this matrix will give what you want.
Amin Ya
  • 1,515
  • 1
  • 19
  • 30