@@ -331,36 +331,109 @@ void HtmlReporter::report(FilterResult* result, Stats* preStats1, Stats* postSta
331331 printSummary (ofs, result, preStats1, postStats1, preStats2, postStats2);
332332
333333 ofs << " <div class='section_div'>\n " ;
334- ofs << " <div class='section_title' onclick=showOrHide('before_filtering')><a name='summary'>Before filtering</a></div>\n " ;
335- ofs << " <div id='before_filtering'>\n " ;
334+ // ofs << "<div class='section_title' onclick=showOrHide('before_filtering')><a name='summary'>Before filtering</a></div>\n";
335+ // ofs << "<div id='before_filtering'>\n";
336336
337+ ofs << " <div class='section_title' onclick=showOrHide('quality_stat')><a name='summary'>Quality statistics</a></div>\n " ;
338+ ofs << " <table id='quality_stat' class='section_table'>\n " ;
339+
340+ string postRead1Name = " read1" ;
341+ if (mOptions ->merge .enabled )
342+ postRead1Name = " merged" ;
343+
344+ // base quality scores
345+ ofs << " <tr><td>\n " ;
337346 if (preStats1) {
338- preStats1 -> reportHtml (ofs, " Before filtering" , " read1" );
347+ preStats1 -> reportHtmlQuality (ofs, " Before filtering" , " read1" );
348+ }
349+ ofs << " </td><td>\n " ;
350+ if (postStats1) {
351+ postStats1 -> reportHtmlQuality (ofs, " After filtering" , postRead1Name);
339352 }
353+ ofs << " </td></tr>\n " ;
340354
355+ ofs << " <tr><td>\n " ;
341356 if (preStats2) {
342- preStats2 -> reportHtml (ofs, " Before filtering" , " read2" );
357+ preStats2 -> reportHtmlQuality (ofs, " Before filtering" , " read2" );
343358 }
359+ ofs << " </td><td>\n " ;
360+ if (postStats2 && !mOptions ->merge .enabled ) {
361+ postStats2 -> reportHtmlQuality (ofs, " After filtering" , " read2" );
362+ }
363+ ofs << " </td></tr>\n " ;
344364
345- ofs << " </div>\n " ;
346- ofs << " </div>\n " ;
365+ // base contents
366+ ofs << " <tr style='height:20px;background:#999999;'></tr>\n " ;
367+ ofs << " <tr><td>\n " ;
368+ if (preStats1) {
369+ preStats1 -> reportHtmlContents (ofs, " Before filtering" , " read1" );
370+ }
371+ ofs << " </td><td>\n " ;
372+ if (postStats1) {
373+ postStats1 -> reportHtmlContents (ofs, " After filtering" , postRead1Name);
374+ }
375+ ofs << " </td></tr>\n " ;
347376
348- ofs << " <div class='section_div'>\n " ;
349- ofs << " <div class='section_title' onclick=showOrHide('after_filtering')><a name='summary'>After filtering</a></div>\n " ;
350- ofs << " <div id='after_filtering'>\n " ;
377+ ofs << " <tr><td>\n " ;
378+ if (preStats2) {
379+ preStats2 -> reportHtmlContents (ofs, " Before filtering" , " read2" );
380+ }
381+ ofs << " </td><td>\n " ;
382+ if (postStats2 && !mOptions ->merge .enabled ) {
383+ postStats2 -> reportHtmlContents (ofs, " After filtering" , " read2" );
384+ }
385+ ofs << " </td></tr>\n " ;
351386
387+ // KMER
388+ ofs << " <tr style='height:20px;background:#999999;'></tr>\n " ;
389+ ofs << " <tr><td>\n " ;
390+ if (preStats1) {
391+ preStats1 -> reportHtmlKMER (ofs, " Before filtering" , " read1" );
392+ }
393+ ofs << " </td><td>\n " ;
352394 if (postStats1) {
353- string name = " read1" ;
354- if (mOptions ->merge .enabled )
355- name = " merged" ;
356- postStats1 -> reportHtml (ofs, " After filtering" , name);
395+ postStats1 -> reportHtmlKMER (ofs, " After filtering" , postRead1Name);
357396 }
397+ ofs << " </td></tr>\n " ;
358398
399+ ofs << " <tr><td>\n " ;
400+ if (preStats2) {
401+ preStats2 -> reportHtmlKMER (ofs, " Before filtering" , " read2" );
402+ }
403+ ofs << " </td><td>\n " ;
359404 if (postStats2 && !mOptions ->merge .enabled ) {
360- postStats2 -> reportHtml (ofs, " After filtering" , " read2" );
405+ postStats2 -> reportHtmlKMER (ofs, " After filtering" , " read2" );
361406 }
407+ ofs << " </td></tr>\n " ;
408+
409+ // over represented seqs
410+ if (mOptions ->overRepAnalysis .enabled ) {
411+ ofs << " <tr style='height:20px;'></tr>\n " ;
412+ ofs << " <tr style='vertical-align: top;'><td>\n " ;
413+ if (preStats1) {
414+ preStats1 -> reportHtmlORA (ofs, " Before filtering" , " read1" );
415+ }
416+ ofs << " </td><td>\n " ;
417+ if (postStats1) {
418+ postStats1 -> reportHtmlORA (ofs, " After filtering" , postRead1Name);
419+ }
420+ ofs << " </td></tr>\n " ;
362421
363- ofs << " </div>\n " ;
422+ ofs << " <tr style='vertical-align: top;'><td>\n " ;
423+ if (preStats2) {
424+ preStats2 -> reportHtmlORA (ofs, " Before filtering" , " read2" );
425+ }
426+ ofs << " </td><td>\n " ;
427+ if (postStats2 && !mOptions ->merge .enabled ) {
428+ postStats2 -> reportHtmlORA (ofs, " After filtering" , " read2" );
429+ }
430+ ofs << " </td></tr>\n " ;
431+ }
432+
433+
434+ ofs << " </table>\n " ;
435+
436+ // ofs << "</div>\n";
364437 ofs << " </div>\n " ;
365438
366439 printFooter (ofs);
@@ -391,6 +464,7 @@ void HtmlReporter::printCSS(ofstream& ofs){
391464 ofs << " .figure {width:800px;height:600px;}" << endl;
392465 ofs << " .header {color:#ffffff;padding:1px;height:20px;background:#000000;}" << endl;
393466 ofs << " .section_title {color:#ffffff;font-size:20px;padding:5px;text-align:left;background:#663355; margin-top:10px;}" << endl;
467+ ofs << " .section_table {width:100%;}" << endl;
394468 ofs << " .subsection_title {font-size:16px;padding:5px;margin-top:10px;text-align:left;color:#663355}" << endl;
395469 ofs << " #container {text-align:center;padding:3px 3px 3px 10px;font-family:Arail,'Liberation Mono', Menlo, Courier, monospace;}" << endl;
396470 ofs << " .menu_item {text-align:left;padding-top:5px;font-size:18px;}" << endl;
0 commit comments