NestedStruct - Represent a nested struct
Version 1.0.2 (2,49 ko) par
Eivind Hennestad
This is a class that will let you display values of all substructs of a struct.
Example:
nestedStruct = struct(...
'Subject', struct('Age', 25, 'Species', 'Mouse'), ...
'Experiment', struct('Date', '2023-01-01', 'Location', 'Lab') );
s = NestedStruct(nestedStruct);
>> s
s =
NestedStruct with properties:
Subject:
Age: 25
Species: 'Mouse'
Experiment:
Date: '2023-01-01'
Location: 'Lab'
Ideas:
- Better display for struct with mix of substructs and values which are not struct
- Support for multiple nesting levels (if possible?)
Citation pour cette source
Eivind Hennestad (2026). NestedStruct - Represent a nested struct (https://fr.mathworks.com/matlabcentral/fileexchange/156199-nestedstruct-represent-a-nested-struct), MATLAB Central File Exchange. Extrait(e) le .
Compatibilité avec les versions de MATLAB
Créé avec
R2023b
Compatible avec les versions R2021b et ultérieures
Plateformes compatibles
Windows macOS LinuxTags
Découvrir Live Editor
Créez des scripts avec du code, des résultats et du texte formaté dans un même document exécutable.
| Version | Publié le | Notes de version | |
|---|---|---|---|
| 1.0.2 | Fields that are not substructs are added as dynamic properties and displayed normally.
|
||
| 1.0.1 | Update description |
||
| 1.0.0 |
