1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82
| for i = an_deb:an_fin;
for j = mois_deb:mois_fin;
for k = jour_deb:jour_fin;
for l = heure_deb:heure_fin;
try
[...]
fichier = dir(fullfile(Directory_source,dossierCourant,'\*.pro'));
%%%%%%%%%%%%%% Boucle: Lecture de tous les fichiers du dossier %%%%%%%%%%%
for p=1:size(fichier,1);
fid=fopen(fullfile(Directory_source,dossierCourant,fichier(p).name),'r');
disp(fid)
%%%%%%%%%%%%%% Lecture des Données voulues %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
[...]
%% Calculs des données voulues
[...]
%%%%%%%%%%%%%% Lecture des voies 1 et voies 2 %%%%%%%%%%%%%%%%%%%%%%%%%%%
[...]
%%%%%%%%%%%%%%%%%%%%%%%%%%%%% Corrélation entre voie 1 et voie 2 %%%%%%%%%
Correl = corr2(voie1, voie2);
if ( Correl > -1 & Correl < 0.0001 );
compteur_corr_bruit_neg = compteur_corr_bruit_neg + 1
fid = fopen('fichiers negatifs.txt','at');
fprintf(fid,'%s\n',fichier(p).name);
fclose(fid);
elseif( Correl > 0.000001 & Correl < 1 );
compteur_corr_95_1_neg = compteur_corr_95_1_neg + 1
fid = fopen('fichiers positifs.txt','at');
fprintf(fid,'%s\n',fichier(p).name);
fclose(fid)
end
if ( (abs(Correl) > 0.5) & (abs(Correl) < 0.6) );
fid = fopen('fichiers_correl_05_06.txt','at');
fprintf(fid,'%s\n',fichier(p).name);
fclose(fid);
compteur_correl_05_a_06 = compteur_correl_05_a_06 +1 ;
elseif ( (abs(Correl) > 0.9) & (abs(Correl) < 0.95) );
fid = fopen('fichiers_correl_09_95.txt','at');
fprintf(fid,'%s\n',fichier(p).name);
fclose(fid);
compteur_correl_09_a_095 = compteur_correl_09_a_095 +1 ;
elseif ( (abs(Correl) > 0.95) & (abs(Correl) < 1) );
if ( (abs(Correl) > 0.95) & (abs(Correl) < 0.97) );
compteur_correl_95_a_97 = compteur_correl_95_a_97 +1 ;
fid = fopen('fichiers_correl_95_97.txt','at');
fprintf(fid,'%s\n',fichier(p).name);
fclose(fid);
elseif ( (abs(Correl) > 0.97) & (abs(Correl) < 1) );
compteur_correl_97_a_1 = compteur_correl_97_a_1 +1 ;
end
end
fclose(fid) ;
end; %end de for
end; % end de try et catch
end
end
end
end |
Partager