[Data, Vars] = Extract(StructArray,[Var1],[Var2],...,[VarN]);
Extracts specified variables from the input Structure Array and returns a single matrix with variables in each column.
Parameters |
Description |
StructArray [struct] |
Structure Array. All sub structures must be identical |
Var1..VarN [string/cell] |
Name of variable to be extracted from StructArray. Any number of variables can be extracted. May be a cell array containing all variables to be extracted. |
Return Values |
Description |
Data [double] |
Matrix of extracted data. Each column is data for one variable. Size of Data will be length(StructArray)xN. If variable does not exist as a field, Data will be empty ([]). |
Vars [cell] |
Cell array of variables returned in Data |
>> G = GeomStruct('Simple',[1000, 3000, 5000, 7000, 10000],50,10000);
>> S = EngagementStruct(G);
>> [Data,Vars] = Extract(S,'S.hp','S.L')
'Tx.DObs',0.1*(0.3:0.1:1.0));
>> Data = Extract(P,'Tx.D','Tx.DObs')
Copyright (c) 2009. All rights reserved.
|
What do you think about this topic? Send feedback!
|