Changeset 1137 for trunk/src/series/merge_proj.m
- Timestamp:
- Apr 24, 2024, 7:45:09 PM (10 days ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/series/merge_proj.m
r1135 r1137 68 68 ParamOut.FieldTransform = 'on';%can use a transform function 69 69 %%%%% list of possible transform functions (needed only for compilation) 70 % ListTransform={'phys','phys_polar','sub_field'};%list of possible transform functions (needed only for compilation) 71 % if 0==1 %never satisfied but trigger compilation with the appropriate transform functions 72 % phys 73 % phys_polar 74 % sub_field 75 try 76 for ilist=1:numel(ListTransform) 77 eval(ListTransform{ilist}) 78 end 79 end 70 if 0==1 %never satisfied but trigger compilation with the appropriate transform functions ('eval' inactive for compilation) 71 phys 72 phys_polar 73 sub_field 74 end 80 75 81 76 ParamOut.TransformPath=fullfile(fileparts(which('uvmat')),'transform_field');% path to transform functions … … 192 187 currentdir=pwd; 193 188 cd(Param.FieldTransform.TransformPath) 189 if strcmp(Param.FieldTransform.TransformName,'sub_field') 190 checksub=2;% the two into field series will be subtracted 191 end 194 192 transform_fct=str2func(Param.FieldTransform.TransformName); 195 193 cd (currentdir) … … 199 197 end 200 198 end 201 checksub=nargin(transform_fct);% number of input arguments for the selected transform fct202 199 if checksub>2 && NbView>2 203 200 disp_uvmat('WARNING',['only the two first input file series will be combined by ' Param.FieldTransform.TransformName],checkrun) … … 321 318 322 319 %% transform the input field iview (e.g; phys) if requested (no transform involving two input fields at this stage) 323 checksub=0; 324 if ~isempty(transform_fct) 320 if ~isempty(transform_fct)&& checksub==0 325 321 checksub=nargin(transform_fct); 326 if checksub>=2322 if nargin(transform_fct)>=2 327 323 Data{iview}=transform_fct(Data{iview},XmlData{iview}); 328 else if checksub==1324 else 329 325 Data{iview}=transform_fct(Data{iview}); 330 326 end … … 356 352 357 353 %% merge the NbView fields 358 % if checksub<=2 354 if checksub==0 359 355 [MergeData,errormsg]=merge_field(Data);%concatene all the input field series by fct merge_data 360 % elseif checksub==3 361 %MergeData=transform_fct(Data{1},XmlData{1},Data{2}); %combine the two input file series362 %else363 %MergeData=transform_fct(Data{1},XmlData{1},Data{2},XmlData{2});%combine the two input file series with calibration parameters364 %end356 else 357 MergeData=transform_fct(Data{1},XmlData{1},Data{2}); %combine the two input file series 358 % else 359 % MergeData=transform_fct(Data{1},XmlData{1},Data{2},XmlData{2});%combine the two input file series with calibration parameters 360 end 365 361 if ~isempty(errormsg) 366 362 disp_uvmat('ERROR',errormsg,checkrun);
Note: See TracChangeset
for help on using the changeset viewer.