istable() returns false for my table
조회 수: 1 (최근 30일)
이전 댓글 표시
I create a table under certain conditions, later want to check if it is a table yet.
Checking in the command window I get this
K>> (app.Results2Table)
ans =
Columns 1 through 5
643705 644260 644760 645000 0
646934 647489 647989 648229 0
650201 0 0 0 0
K>> istable(app.Results2Table)
ans =
logical
0
Looks like a table to me
댓글 수: 0
채택된 답변
Les Beckham
2025년 7월 15일
이동: Walter Roberson
2025년 7월 15일
That is definitely not a table. You can confirm that with the whos command. Tables are formatted differently when displayed. Specifically, they have variable names (that look like column titles).
댓글 수: 3
Steven Lord
2025년 7월 16일
If you preallocated it to contain a certain amount of data like the following, that makes it an array (or since this is 2-dimensional, a matrix as per the definition used by the ismatrix function.) All table arrays are matrices, but it is not the case that all matrices or all arrays are tables.
a = zeros(5) % matrix and array, but not a table
Or if you did this, that makes it a cell array not a table.
b = {1, 2, 3, 4, 5}
추가 답변 (0개)
참고 항목
카테고리
Help Center 및 File Exchange에서 Tables에 대해 자세히 알아보기
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!