Changeset 389 for trunk/src/read_civdata.m
- Timestamp:
- Apr 8, 2012, 11:11:38 PM (12 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/read_civdata.m
r382 r389 83 83 Field.ListGlobalAttribute=[Field.ListGlobalAttribute {'Dt'}]; 84 84 var_ind=find(vardetect); 85 for ivar=1: min(numel(var_ind),numel(Field.VarAttribute))85 for ivar=1:numel(var_ind) 86 86 Field.VarAttribute{ivar}.Role=role{var_ind(ivar)}; 87 87 Field.VarAttribute{ivar}.Unit=units{var_ind(ivar)}; … … 95 95 Field.TimeUnit='s'; 96 96 Field.CoordUnit='pixel'; 97 98 99 97 100 98 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% … … 122 120 for ilist=1:length(FieldNames) 123 121 if ~isempty(FieldNames{ilist}) 124 switch FieldNames{ilist}125 case{'u','v'}126 testpatch=1;127 case {'vort','div','strain'}128 testder=1;129 122 switch FieldNames{ilist} 123 case{'u','v'} 124 testpatch=1; 125 case {'vort','div','strain'} 126 testder=1; 127 end 130 128 end 131 end 132 end 133 129 end 134 130 if isempty(vel_type) 135 131 switch CivStage … … 153 149 154 150 switch vel_type 155 case {'civ1','filter1'}156 var={'X','Y','Z','U','V','W','C','F','FF',' X_tps','Y_tps','Z_tps','U_tps','V_tps','W_tps','X_SubRange','Y_SubRange','NbSites','Indices_tps';...151 case 'civ1' 152 var={'X','Y','Z','U','V','W','C','F','FF','Coord_tps','U_tps','V_tps','W_tps','SubRange','NbSites';... 157 153 'Civ1_X','Civ1_Y','Civ1_Z','Civ1_U','Civ1_V','Civ1_W','Civ1_C','Civ1_F','Civ1_FF',... 158 'Civ1_X_tps','Civ1_Y_tps','','Civ1_U_tps','Civ1_V_tps','','Civ1_X_SubRange','Civ1_Y_SubRange','Civ1_NbSites','Civ1_Indices_tps'}; 159 role={'coord_x','coord_y','coord_z','vector_x','vector_y','vector_z','ancillary','warnflag','errorflag','','','','','','','','','',''}; 160 units={'pixel','pixel','pixel','pixel','pixel','pixel','','','','pixel','pixel','pixel','pixel','pixel','pixel','pixel','pixel','',''}; 161 case 'civ-filter1' 162 var={'X','Y','Z','U','V','W','FF';... 163 'Civ1_X','Civ1_Y','','Civ1_U_Diff','Civ1_V_Diff','','Civ1_FF'}; 164 role={'coord_x','coord_y','coord_z','vector_x','vector_y','vector_z','errorflag'}; 165 units={'pixel','pixel','pixel','pixel','pixel','pixel',[]}; 166 % case 'filter1' 167 % var={'X_tps','Y_tps','Z_tps','U_tps','V_tps','W_tps','X_SubRange','Y_SubRange','NbSites','Indices_tps';... 168 % 'Civ1_X_tps','Civ1_Y_tps','','Civ1_U_tps','Civ1_V_tps','','Civ1_X_SubRange','Civ1_Y_SubRange','Civ1_NbSites','Civ1_Indices_tps'}; 169 % role={'','','','','','','','','',''}; 170 % units={'pixel','pixel','pixel','pixel','pixel','pixel','pixel','pixel','',''}; 171 case {'civ2','filter2'} 172 var={'X','Y','Z','U','V','W','C','F','FF','X_tps','Y_tps','Z_tps','U_tps','V_tps','W_tps','X_SubRange','Y_SubRange','NbSites','Indices_tps';... 154 'Civ1_Coord_tps','Civ1_U_tps','Civ1_V_tps','Civ1_W_tps','Civ1_SubRange','Civ1_NbSites'}; 155 role={'coord_x','coord_y','coord_z','vector_x','vector_y','vector_z','ancillary','warnflag','errorflag','ancillary','ancillary',... 156 'ancillary','ancillary','ancillary','ancillary'}; 157 units={'pixel','pixel','pixel','pixel','pixel','pixel','','','','pixel','pixel','pixel','pixel','pixel',''}; 158 case 'filter1' 159 var={'X','Y','Z','U','V','W','C','F','FF','Coord_tps','U_tps','V_tps','W_tps','SubRange','NbSites';... 160 'Civ1_X','Civ1_Y','Civ1_Z','Civ1_U_smooth','Civ1_V_smooth','Civ1_W','Civ1_C','Civ1_F','Civ1_FF',... 161 'Civ1_Coord_tps','Civ1_U_tps','Civ1_V_tps','Civ1_W_tps','Civ1_SubRange','Civ1_NbSites'}; 162 role={'coord_x','coord_y','coord_z','vector_x','vector_y','vector_z','ancillary','warnflag','errorflag','ancillary','ancillary',... 163 'ancillary','ancillary','ancillary','ancillary'}; 164 units={'pixel','pixel','pixel','pixel','pixel','pixel','','','','pixel','pixel','pixel','pixel','pixel',''}; 165 case 'civ2' 166 var={'X','Y','Z','U','V','W','C','F','FF','Coord_tps','U_tps','V_tps','W_tps','SubRange','NbSites';... 173 167 'Civ2_X','Civ2_Y','Civ2_Z','Civ2_U','Civ2_V','Civ2_W','Civ2_C','Civ2_F','Civ2_FF',... 174 'Civ2_X_tps','Civ2_Y_tps','','Civ2_U_tps','Civ2_V_tps','','Civ2_X_SubRange','Civ2_Y_SubRange','Civ2_NbSites','Civ2_Indices_tps'}; 175 role={'coord_x','coord_y','coord_z','vector_x','vector_y','vector_z','ancillary','warnflag','errorflag','','','','','','','','','',''}; 176 units={'pixel','pixel','pixel','pixel','pixel','pixel','','','','pixel','pixel','pixel','pixel','pixel','pixel','pixel','pixel','',''}; 177 % var={'X','Y','Z','U','V','W','C','F','FF';... 178 % 'Civ2_X','Civ2_Y','Civ2_Z','Civ2_U','Civ2_V','Civ2_W','Civ2_C','Civ2_F','Civ2_FF'}; 179 % role={'coord_x','coord_y','coord_z','vector_x','vector_y','vector_z','ancillary','warnflag','errorflag'}; 180 % units={'pixel','pixel','pixel','pixel','pixel','pixel',[],[],[]}; 181 case 'civ-filter2' 182 var={'X','Y','Z','U','V','W','FF';... 183 'Civ2_X','Civ2_Y','','Civ2_U_Diff','Civ2_V_Diff','','Civ2_FF'}; 184 role={'coord_x','coord_y','coord_z','vector_x','vector_y','vector_z','errorflag'}; 185 units={'pixel','pixel','pixel','pixel','pixel','pixel',[]}; 186 % case 'filter2' 187 % var={'X_tps','Y_tps','Z_tps','U_tps','V_tps','W_tps','X_SubRange','Y_SubRange','NbSites','Indices_tps';... 188 % 'Civ2_X_tps','Civ2_Y_tps','','Civ2_U_tps','Civ2_V_tps','','Civ2_X_SubRange','Civ2_Y_SubRange','Civ2_NbSites','Civ2_Indices_tps'}; 189 % role={'','','','','','','','','',''}; 190 % units={'pixel','pixel','pixel','pixel','pixel','pixel','pixel','pixel','',''}; 168 'Civ2_Coord_tps','Civ2_U_tps','Civ2_V_tps','','Civ2_SubRange','Civ2_NbSites'}; 169 role={'coord_x','coord_y','coord_z','vector_x','vector_y','vector_z','ancillary','warnflag','errorflag','','','','','','','',''}; 170 units={'pixel','pixel','pixel','pixel','pixel','pixel','','','','pixel','pixel','pixel','pixel','pixel',''}; 171 case 'filter2' 172 var={'X','Y','Z','U','V','W','C','F','FF','Coord_tps','U_tps','V_tps','W_tps','SubRange','NbSites';... 173 'Civ2_X','Civ2_Y','Civ2_Z','Civ2_U_smooth','Civ2_V_smooth','Civ2_W','Civ2_C','Civ2_F','Civ2_FF',... 174 'Civ2_Coord_tps','Civ2_U_tps','Civ2_V_tps','','Civ2_SubRange','Civ2_NbSites'}; 175 role={'coord_x','coord_y','coord_z','vector_x','vector_y','vector_z','ancillary','warnflag','errorflag','','','','','','','',''}; 176 units={'pixel','pixel','pixel','pixel','pixel','pixel','','','','pixel','pixel','pixel','pixel','pixel',''}; 191 177 end 192 178 vel_type_out=vel_type;
Note: See TracChangeset
for help on using the changeset viewer.