- Timestamp:
- Feb 2, 2011, 1:22:05 AM (14 years ago)
- Location:
- trunk/src
- Files:
-
- 7 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/civ.m
r183 r188 4625 4625 hwaitbar=uicontrol('Style','frame','Units','normalized', 'Position',BarPosition ,'BackgroundColor',[1 0 0],'tag','waitbar'); 4626 4626 end 4627 datnum=[];4627 % datnum=[]; 4628 4628 Tabchar={}; 4629 4629 nbfiles=numel(civ_files); 4630 4630 count=0; 4631 testrecent=0; 4631 4632 while count<nbfiles 4632 4633 count=0; 4634 datnum=zeros(1,nbfiles); 4633 4635 for ifile=1:nbfiles 4634 4636 detect=exist(civ_files{ifile},'file'); % check the existence of the file … … 4637 4639 option_str='not created'; 4638 4640 else 4639 datfile=dir(civ_files{ifile}); 4640 datnum(ifile)=datenum(datfile.date); 4641 datfile=dir(civ_files{ifile}) 4642 if isfield(datfile,'datenum') 4643 datnum(ifile)=datfile.datenum;%only available in recent matlab versions 4644 testrecent=1; 4645 end 4641 4646 filefound(ifile)={datfile.name}; 4642 4647 lastfield=''; … … 4669 4674 Tabchar{ifile,1}=[fullfile([subdir extdir],filename) ext '...' option_str]; 4670 4675 end 4671 if isempty(datnum) 4672 message='no civ result created yet'; 4676 datnum=datnum(find(datnum));%keep the non zero values corresponding to existing files 4677 if isempty(datnum) 4678 if testrecent 4679 message='no civ result created yet'; 4680 else 4681 message=''; 4682 end 4673 4683 else 4674 4684 datnum=datnum(find(datnum));%keep the non zero values corresponding to existing files … … 4708 4718 ind_dot=findstr(filename,'...'); 4709 4719 filename=filename(1:ind_dot-1); 4710 filename=fullfile(rootroot,filename) 4720 filename=fullfile(rootroot,filename); 4711 4721 if exist(filename,'file')%visualise the vel field if it exists 4712 4722 %[Field,VelTypeOut]=read_civxdata(filename); -
trunk/src/get_field.m
r187 r188 810 810 huvmat=findobj(allchild(0),'tag','uvmat'); 811 811 if isempty(huvmat) 812 inputfile=get(handles.inputfile,'String');813 812 uvmat(inputfile) 814 813 else … … 830 829 browse_fig(handles.list_fig); %update the list of new existing figures 831 830 end 831 set(handles.RUN,'BackgroundColor',[1 0 0]) 832 832 833 833 %------------------------------------------------------------------------ -
trunk/src/nc2struct.m
r150 r188 103 103 indstr1=regexp(keystr,'\\','once');%detect '\\' 104 104 indstr2=regexp(keystr,'\.','once');%detect '\.' 105 if isempty(indstr1) && isempty(indstr2) 105 %indtitle=regexp(keystr,'title','once');%detect 'title'(bad characters) 106 if isempty(indstr1) && isempty(indstr2)%&&isempty(indtitle) 106 107 valuestr = netcdf.getAtt(nc,netcdf.getConstant('NC_GLOBAL'),keystr); 107 if ischar(valuestr) & & length(valuestr)<200108 if ischar(valuestr) & length(valuestr)<200 & double(valuestr)<=122 & double(valuestr)>=48 %usual characters 108 109 iatt_g=iatt_g+1; 109 110 indstr1=regexp(keystr,'\\','once');%detect '\\' -
trunk/src/plot_field.m
r187 r188 239 239 tagaxes=get(haxes,'tag'); 240 240 if isfield(FigData,tagaxes) 241 eval(['FigData.' tagaxes '=Data '])241 eval(['FigData.' tagaxes '=Data;']) 242 242 set(hfig,'UserData',FigData) 243 243 end -
trunk/src/series.m
r179 r188 1015 1015 ref_i=str2num(get(handles.ref_i,'String')); 1016 1016 ref_j=str2num(get(handles.ref_j,'String')); 1017 % time=[]; 1018 % ref_time=[]; 1019 ref_time=0; 1020 % if isfield(SeriesData,'Time')&~isempty(SeriesData.Time{Val})&~isequal(SeriesData.Time{Val},0) 1021 % time=SeriesData.Time{Val}; %get the set of times 1022 % siztime=size(time); 1023 % nbfield=siztime(1); 1024 % nbfield2=siztime(2); 1025 % % test_imadoc=1; 1026 % else 1027 % test_imadoc=0;%no image documentation file 1028 nbfield=50; 1029 nbfield2=50;%default max number of pairs 1030 % end 1017 ref_time=0; 1018 nbfield=50; 1019 nbfield2=50;%default max number of pairs 1020 1031 1021 %look for existing processed pairs involving the field at the middle of the series if civ1 will not 1032 1022 % be performed, while the result is needed for next steps. … … 1041 1031 end 1042 1032 if strcmp(mode,'series(Di)') 1043 nbfield1044 1033 for index=1:min(nbfield-1,50) 1045 1034 filename=name_generator(filebase,ref_i-floor(index/2),ref_j,'.nc',NomType,1,ref_i+ceil(index/2),ref_j,subdir); … … 1079 1068 displ_num(3,ind_exist)=0; 1080 1069 displ_num(4,ind_exist)=0; 1081 %[cte_detect,vdt,cte_read]=read_netcdf(filename,{'dt','dt2','absolut_time_T0','absolute_time_TO_2'});1082 1070 [Cte,var_detect,ichoice]=nc2struct(filename,{}); 1083 1071 if isfield(Cte,'dt2')
Note: See TracChangeset
for help on using the changeset viewer.