#include "sopnamsp.h" #include "machdefs.h" #include #include #include #include #include #include #include "timing.h" #include "histerr.h" void usage(void); void usage(void) { cout<<"cmvconchprof -n name_histoerr file1.ppf file2.ppf ..."< ppfname; // --- Decodage arguments char c; while((c = getopt(narg,arg,"hn:")) != -1) { switch (c) { case 'n' : nameh = optarg; break; case 'h' : default : usage(); return -1; } } if(nameh.size()<=0 || optind>=narg) {usage(); return -1;} for (int i=optind;iAddBin(i,herr(i)); sum+=herr(itest); sum2+=herr(itest)*herr(itest), nsum++; } herrconc->ToCorrel(); if(nsum>0) {sum/=nsum; sum2/=nsum; sum2-=sum*sum;} cout<<"Test bin "< variance_pkz\n"); for(int i=0;iNBins();i++) { double k = herrconc->BinCenter(i); fprintf(fdata,"%e %e %e\n",k,(*herrconc)(i),herrconc->Error2(i)); } fclose(fdata); } // --- ecriture ppf string tagobs = "cmvconchprof.ppf"; POutPersist posobs(tagobs); tagobs = "herrconc"; posobs.PutObject(*herrconc,tagobs); delete herrconc; return 0; } /* openppf cmvconchprof.ppf disp herrconc n/plot herrconc.val%log10(x) x>0 ! "connectpoints" n/plot herrconc.err%log10(x) x>0 ! "connectpoints same red" n/plot herrconc.err/val%log10(x) x>0&&val>0 ! "connectpoints" */