Extract the values corresponding to the specific filed in the struct

3 vues (au cours des 30 derniers jours)
Ting-Yu Chueh
Ting-Yu Chueh le 20 Jan 2023
Commenté : Stephen23 le 20 Jan 2023
Dear all,
I want to extract the all informaiton of the type field of ' S1 ' from the struct so that I can konw the latency and duration etc. about ' S 1 '.
Please see the attached figure and data. Thanks.

Réponse acceptée

KSSV
KSSV le 20 Jan 2023
Modifié(e) : KSSV le 20 Jan 2023
iwant = [S(:).latency]
Else other option, would be convert your structure to table and access the data you want.
T = struc2table(S)

Plus de réponses (0)

Catégories

En savoir plus sur Data Type Conversion dans Help Center et File Exchange

Community Treasure Hunt

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

Start Hunting!

Translated by