How can I fetch the list of fields in a structure? Regards, Preetam

 Akzeptierte Antwort

Weitere Antworten (1)

Shivam
Shivam am 30 Jul. 2022

0 Stimmen

You can fetch the fields of a structure S using fieldname this way.
fields = fieldnames(S)
It returns the field names of the structure array S in a cell array.

Kategorien

Tags

Community Treasure Hunt

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

Start Hunting!

Translated by