Get data out of a struct to manipulate
4 vues (au cours des 30 derniers jours)
Afficher commentaires plus anciens
I have created a struct where the first bit is just a name, and the second bit is a bunch of data

I want to get the data out of the struct so I can manipulate it and put it into a table or an array
0 commentaires
Réponses (1)
Cris LaPierre
le 14 Juil 2023
Extract the data using the structurename.fieldname syntax. See here: https://www.mathworks.com/help/matlab/matlab_prog/create-a-structure-array.html
% create the structure
patient.test = [79 75 73; 180 178 177.5; 220 210 205]
% Extract the data
data = patient.test
0 commentaires
Voir également
Catégories
En savoir plus sur Structures 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!