How to Set Up If/Else Statement with Condition of Seeing if Item in Structure Array is a Table

3 次查看(过去 30 天)
Hello,
I have a structure array with variable number of items.
Some of these items are just words, saying something like 'This is not what you need'.
The rest of the items are a table.
I eventually want to plot one of the columns of each table in the structure array vs another vector
I want to do an if statement that checks if the item is a table, so something like:
for i=1:N
if struct(i).Day == table
scatter(Time_Vector,struct(i).Day(:,2))
else
end
end
Is this something that is possible in MATLAB?
If my question doesn't make sense, I can elaborate.
Thanks.

采纳的回答

Les Beckham
Les Beckham 2022-12-14
I suggest the istable function. Documentation is here

更多回答(0 个)

类别

Help CenterFile Exchange 中查找有关 Logical 的更多信息

产品


版本

R2021a

Community Treasure Hunt

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

Start Hunting!

Translated by