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

조회 수: 4 (최근 30일)
hithere
hithere 2014년 10월 31일
댓글: Jan 2014년 11월 1일
.
.
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일
x = unique(wavelengtha_5(:));

추가 답변 (2개)

Azzi Abdelmalek
Azzi Abdelmalek 2014년 10월 31일
They are already in the same variable, but if you mean how to reshape for example the variable x
out=x(:)
  댓글 수: 3
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일
I think you are looking for UNIQUE.

카테고리

Help CenterFile Exchange에서 Logical에 대해 자세히 알아보기

태그

Community Treasure Hunt

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

Start Hunting!

Translated by