From ae9e4069dba2374a1f7d708bd4f61e91bb123ed6 Mon Sep 17 00:00:00 2001 From: Veronique Legrand <vlegrand@pasteur.fr> Date: Tue, 11 May 2021 15:19:14 +0200 Subject: [PATCH] limit to 2 digits after dot the number of digits displayed for flase positive probability --- src/rock.cpp | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/rock.cpp b/src/rock.cpp index 1b31882..450eae0 100755 --- a/src/rock.cpp +++ b/src/rock.cpp @@ -83,7 +83,7 @@ const void printVerboseInfo(const ROCKparams& Rparms,const Filter& filter,const cout<<setw(40)<<left<<"expected no. distinct k-mers"<<Rparms.get_expected_nbKmers()<<endl; cout<<setw(40)<<left<<"no. hash. function(s)"<<parms.lambda<<endl; - cout<<setw(40)<<left<<"expected false positive proba."<<Rparms.get_expected_collision_proba()<<" (cov. depth > 1)"<<endl; + cout<<setw(40)<<left<<"expected false positive proba."<<setprecision (2)<<fixed<<Rparms.get_expected_collision_proba()<<" (cov. depth > 1)"<<endl; for (int i=0;i<parms.lambda;i++) { string tmp="no. buckets for hash. "; @@ -105,13 +105,13 @@ const void printVerboseInfo(const ROCKparams& Rparms,const Filter& filter,const int smallest_kappa=parms.kappa; if (parms.kappa_prime>0) smallest_kappa=parms.kappa_prime; float p =getCollisionProba(smallest_kappa,approx_nbDiffKm,Pi_js[0],parms.lambda); - cout<<setw(40)<<left<<"approx. false positive proba."<<p<<endl; + cout<<setw(40)<<left<<"approx. false positive proba."<<setprecision (2)<<p<<endl; cout<<setw(40)<<left<<"no. selected reads"<<rc.nb_output_reads<<endl; for (it_pe=v_PE_files.begin();it_pe!=v_PE_files.end();it_pe++) { cout<<setw(40)<<left<<"PE output files"<<it_pe->PE1.out_fq_file<<" "<<it_pe->PE2.out_fq_file<<" "<<it_pe->PE1.undef_fq_file<<" "<<it_pe->PE2.undef_fq_file<<endl; } for (it_s=single_files.begin();it_s!=single_files.end();it_s++) { - cout<<setw(40)<<left<<"SE output file(s)"<<it_s->out_fq_file<<" "<<it_s->undef_fq_file<<endl; + cout<<setw(40)<<left<<"SE output files"<<it_s->out_fq_file<<" "<<it_s->undef_fq_file<<endl; } } -- GitLab