Pack & Unpack variables to & from structures with enhanced functionality
v2struct packs and unpacks variables to and from structures with enhanced functionality.
You are now following this Submission
- You will see updates in your followed content feed
- You may receive emails, depending on your communication preferences
Editor's Note: This file was selected as MATLAB Central Pick of the Week
Cite As
Adi Navve (2026). Pack & Unpack variables to & from structures with enhanced functionality (https://nl.mathworks.com/matlabcentral/fileexchange/31532-pack-unpack-variables-to-from-structures-with-enhanced-functionality), MATLAB Central File Exchange. Retrieved .
Acknowledgements
Inspired: eval_test_list, struct2vars, vars2struct, Apply multiple functions in a single function., Crop video to sub elements
General Information
- Version 1.14.0 (25.9 KB)
MATLAB Release Compatibility
- Compatible with any release
Platform Compatibility
- Windows
- macOS
- Linux
Communities
| Version | Published | Release Notes | Action |
|---|---|---|---|
| 1.14.0 | Made submission availavble as a toolbox |
||
| 1.13.0 | Added easy packing of all variables in caller workspace (thanks to Vesa Lehtinen for the suggestion), fixed bug in warning handling in packing case, edited comments. |
||
| 1.11.0 | Clarified warning and error when packing/unpacking with fieldNames. |
||
| 1.8.0 | fixed bug in packing with variables only |
||
| 1.7.0 | fieldNames usage corrected, now for triggering a specific string must be included. Documentation enhanced. Code tweaked. |
||
| 1.5.0 | * Added functionality: avoid overwritring existing variables
|
||
| 1.4.0 | added update structure functionality, made some documentation and demo function changes, added image :) |
||
| 1.0.0 |