How to union columns in the same Variable (Array) ?

.
.
How do i union column 1,2,3.... 9 together in this case? All in the same variable.

1 件のコメント

Jan
Jan 2014 年 11 月 1 日
Please do not post screen shots. It makes it much harder to create an answer.

サインインしてコメントする。

 採用された回答

Jan
Jan 2014 年 11 月 1 日

0 投票

x = unique(wavelengtha_5(:));

その他の回答 (2 件)

Azzi Abdelmalek
Azzi Abdelmalek 2014 年 10 月 31 日

0 投票

They are already in the same variable, but if you mean how to reshape for example the variable x
out=x(:)

3 件のコメント

hithere
hithere 2014 年 11 月 1 日
Hi. but it doesnt add up in running sequence.
Azzi Abdelmalek
Azzi Abdelmalek 2014 年 11 月 1 日
What do you mean?
hithere
hithere 2014 年 11 月 1 日
編集済み: hithere 2014 年 11 月 1 日
for example the variables is like this:
1 2 6
3 4 10
5 8 12
7 11 13
9 14 15
if they were in different variable, a union function will be
1
2
3
4
5
6
7
8
.
.
.
15
in ascending order and eliminating duplicates.
So im think how to have the same effect in this scenario.

サインインしてコメントする。

Peter Perkins
Peter Perkins 2014 年 11 月 1 日

0 投票

I think you are looking for UNIQUE.

1 件のコメント

hithere
hithere 2014 年 11 月 1 日
how should i go about doing that?

サインインしてコメントする。

カテゴリ

タグ

質問済み:

2014 年 10 月 31 日

コメント済み:

Jan
2014 年 11 月 1 日

Community Treasure Hunt

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

Start Hunting!

Translated by