MATLAB: What is the difference between structure and table

datadifferencestructstructuretabletype

For me, they looks very similar. I'm not sure when I should use table or structure.
Structure
Table

Best Answer

table has a nicer output presentation, and should be more efficient in memory. It also has some useful operations especially when you start getting into timetable objects.
table makes it easier to select subsets of the data. For example you might want to select the excitation and fft of all the entries on a particular date. With struct you would do something like construct mask to select particular structure entries and then do
out = struct('excitation', S(mask).excitation, 'fft', S(mask).fft);
Whereas with tables it would be
out = T(mask, {'excitation', 'fft'}) ;
Or
out = T(mask, [4,7]);
However, table are slower than structures.
Related Question