How to delete empty lines in a table

Hello all, I have an easy question for you. How would you delete all empty lines in a table? Thank you

댓글 수: 1

Image Analyst
Image Analyst 2016년 7월 3일
Start with the last row and work up using a for loop. Are all the columns of the same data type, like double? Or is there a mix of data types? Can you supply a sample table?

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

답변 (1개)

Azzi Abdelmalek
Azzi Abdelmalek 2016년 7월 3일

2 개 추천

If A is your table
idx=all(cellfun(@isempty,A{:,:}),2)
A(idx,:)=[]

카테고리

도움말 센터File Exchange에서 Tables에 대해 자세히 알아보기

태그

질문:

2016년 7월 3일

댓글:

2016년 7월 3일

Community Treasure Hunt

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

Start Hunting!

Translated by