Display the value instead of 1x1 table

조회 수: 66 (최근 30일)
Riccardo Tronconi
Riccardo Tronconi 2021년 9월 14일
편집: Cris LaPierre 2021년 9월 14일
Hi guys how to display in my output the value instead of 1x1 table?
This is my matrix T:
{1×1 table} {[12544]} {1×1 table} {[12544]} {[ 0]}
{1×1 table} {[12559]} {1×1 table} {[12561]} {[ 0]}
{1×1 table} {[12722]} {1×1 table} {[12722]} {[ 0]}
{1×1 table} {[12751]} {1×1 table} {[12756]} {[ 1]}
{1×1 table} {[12789]} {1×1 table} {[12794]} {[ 2]}
{1×1 table} {[12803]} {1×1 table} {[12815]} {[ 1]}
{1×1 table} {[12875]} {1×1 table} {[12880]} {[ 4]}
{1×1 table} {[12917]} {1×1 table} {[12917]} {[ 0]}
{1×1 table} {[13763]} {1×1 table} {[13763]} {[ 0]}
{1×1 table} {[14038]} {1×1 table} {[14047]} {[ 4]}
{1×1 table} {[14092]} {1×1 table} {[14094]} {[ 2]}
{1×1 table} {[15444]} {1×1 table} {[15457]} {[ 10]}

채택된 답변

Cris LaPierre
Cris LaPierre 2021년 9월 14일
편집: Cris LaPierre 2021년 9월 14일
This is likely an issue with how you have assigned values to your cell array. Rather than assigne a table to a cell, assign its value. See this page on how to access data in a table.
a=5; A = table(a);
% Assigns table
C{1} = A
C = 1×1 cell array
{1×1 table}
% Assigns value
D{1} = A.a
D = 1×1 cell array
{[5]}
Better yet would be to use a table to capture all your values rather than a cell.
a=6; b=7; c=8; d=9; e=10;
data = table(a,b,c,d,e)
data = 1×5 table
a b c d e _ _ _ _ __ 6 7 8 9 10

추가 답변 (0개)

카테고리

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

태그

Community Treasure Hunt

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

Start Hunting!

Translated by