필터 지우기
필터 지우기

Erase row from a cell-array

조회 수: 2 (최근 30일)
Maria
Maria 2014년 7월 27일
댓글: Image Analyst 2014년 7월 27일
I have the following cell variable with 10000 rows:
A={ 'x' 'start1' 'end1'
12 1997 2000
13 1997 1999
16 1997 2002 }
And I would like to delete the first row. I tried the following code:
A(cell2mat(A(1,:)))=[];
but it returns the values all in one row, instead of the way theu were originally disposed.
Cna someone help me? Thanks
  댓글 수: 1
Image Analyst
Image Analyst 2014년 7월 27일
You might not have had to ask if you were more knowledgeable about cell arrays. Please read the FAQ http://matlab.wikia.com/wiki/FAQ#What_is_a_cell_array.3F I think it might give you a better intuitive feel for what cells are and how to reference them. If you understood this, you might not have tried that cell2mat stuff, and would have know to do Azzi's answer.

댓글을 달려면 로그인하십시오.

채택된 답변

Azzi Abdelmalek
Azzi Abdelmalek 2014년 7월 27일

추가 답변 (0개)

카테고리

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