%% BioMed_Central_Tex_Template_v1.05
%%                                      %
%  bmc_article.tex            ver: 1.05 %
%                                       %


%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%%                                     %%
%%  LaTeX template for BioMed Central  %%
%%     journal article submissions     %%
%%                                     %%
%%         <27 January 2006>           %%
%%                                     %%
%%                                     %%
%% Uses:                               %%
%% cite.sty, url.sty, bmc_article.cls  %%
%% ifthen.sty. multicol.sty            %%
%%                                     %%
%%                                     %%
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%


%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%%                                                                 %%	
%% For instructions on how to fill out this Tex template           %%
%% document please refer to Readme.pdf and the instructions for    %%
%% authors page on the biomed central website                      %%
%% http://www.biomedcentral.com/info/authors/                      %%
%%                                                                 %%
%% Please do not use \input{...} to include other tex files.       %%
%% Submit your LaTeX manuscript as one .tex document.              %%
%%                                                                 %%
%% All additional figures and files should be attached             %%
%% separately and not embedded in the \TeX\ document itself.       %%
%%                                                                 %%
%% BioMed Central currently use the MikTex distribution of         %%
%% TeX for Windows) of TeX and LaTeX.  This is available from      %%
%% http://www.miktex.org                                           %%
%%                                                                 %%
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%


\NeedsTeXFormat{LaTeX2e}[1995/12/01]
\documentclass[10pt]{bmc_article}    



% Load packages
\usepackage{cite} % Make references as [1-4], not [1,2,3,4]
\usepackage{url}  % Formatting web addresses  
\usepackage{ifthen}  % Conditional 
\usepackage{multicol}   %Columns
\usepackage[utf8]{inputenc} %unicode support
%\usepackage[applemac]{inputenc} %applemac support if unicode package fails
%\usepackage[latin1]{inputenc} %UNIX support if unicode package fails
\usepackage{siunitx}
\usepackage{etoolbox}
\usepackage{booktabs}
\usepackage{xspace}
\urlstyle{rm}
 
 
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%	
%%                                             %%
%%  If you wish to display your graphics for   %%
%%  your own use using includegraphic or       %%
%%  includegraphics, then comment out the      %%
%%  following two lines of code.               %%   
%%  NB: These line *must* be included when     %%
%%  submitting to BMC.                         %% 
%%  All figure files must be submitted as      %%
%%  separate graphics through the BMC          %%
%%  submission process, not included in the    %% 
%%  submitted article.                         %% 
%%                                             %%
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%                     


\def\includegraphic{}
\def\includegraphics{}



\setlength{\topmargin}{0.0cm}
\setlength{\textheight}{21.5cm}
\setlength{\oddsidemargin}{0cm} 
\setlength{\textwidth}{16.5cm}
\setlength{\columnsep}{0.6cm}

\newboolean{publ}

%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%%                                              %%
%% You may change the following style settings  %%
%% Should you wish to format your article       %%
%% in a publication style for printing out and  %%
%% sharing with colleagues, but ensure that     %%
%% before submitting to BMC that the style is   %%
%% returned to the Review style setting.        %%
%%                                              %%
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 

%Review style settings
%\newenvironment{bmcformat}{\begin{raggedright}\baselineskip20pt\sloppy\setboolean{publ}{false}}{\end{raggedright}\baselineskip20pt\sloppy}

%Publication style settings
\newenvironment{bmcformat}{\fussy\setboolean{publ}{true}}{\fussy}



% Begin ...
\begin{document}
\begin{bmcformat}

%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%% Formatting macros
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\newcommand{\quorum}{QuorUM\xspace}
\hyphenation{quor-um}
\newcommand{\species}[1]{\textit{#1}}
\newcommand{\cov}[1]{\ensuremath #1\textrm{x}\xspace}

%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%%                                          %%
%% Enter the title of your article here     %%
%%                                          %%
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\title{\quorum: an error corrector for Illumina reads}
 
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%%                                          %%
%% Enter the authors here                   %%
%%                                          %%
%% Ensure \and is entered between all but   %%
%% the last two authors. This will be       %%
%% replaced by a comma in the final article %%
%%                                          %%
%% Ensure there are no trailing spaces at   %% 
%% the ends of the lines                    %%     	
%%                                          %%
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%


\author{Guillaume Mar\c{c}ais\correspondingauthor$^1$%
       \email{Guillaume Mar\c{c}ais\correspondingauthor - gmarcais@umd.edu}%
      \and
         Aleksey Zimin\correspondingauthor$^1$%
         \email{Aleksey Zimin\correspondingauthor- alekseyz@ipst.umd.edu}%
       \ and
         James A. Yorke$^1$%
         \email{James Yorke - yorke@umd.edu}
      }
      

%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%%                                          %%
%% Enter the authors' addresses here        %%
%%                                          %%
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%

\address{%
    \iid(1)University of Maryland, College Park, MD
}%

\maketitle

%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%%                                          %%
%% The Abstract begins here                 %%
%%                                          %%
%% The Section headings here are those for  %%
%% a Research article submitted to a        %%
%% BMC-Series journal.                      %%  
%%                                          %%
%% If your article is not of this type,     %%
%% then refer to the Instructions for       %%
%% authors on http://www.biomedcentral.com  %%
%% and change the section headings          %%
%% accordingly.                             %%   
%%                                          %%
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%


\begin{abstract}
  % Do not use inserted blank lines (ie \\) until main body of text.
\paragraph*{Background:}
Illumina Sequencing data can provide high coverage of a genome by relatively short (\SI{100}{bp} to \SI{150}{bp}) reads at a low cost.
The base error rates in the reads vary greatly along the read sequence.
Low quality bases can be trimmed off or error-corrected.
Trimming, especially based on the quality scores, can eliminate large amounts of useful sequence in the reads.
Error correction is an alternative to trimming that takes advantage of the high coverage of the genome to make the high confidence base corrections in the reads.
Error correction allows for more effective use of the sequencing data thus reducing the coverage depth requirements in sequencing projects and increasing the quality of the resulting assemblies.
The vast majority of errors in Illumina data are substitutions, where a base call is incorrect, and \quorum focuses on this type of error.
The software is available under the GPL open source license at \url{ftp://ftp.genome.umd.edu/pub/quorum}.
      
\paragraph*{Results:}
We propose software, called \quorum, for error correcting substitution error in Illumina reads.
It provides accurate correction and is suitable for large data sets ($48$ billion bases corrected per hours on $48$ threads).

\paragraph*{Conclusions:} 
For each test of the three genomes, either Quake or \quorum performed best (see Table~\ref{table:left-introduced}).
Generally, Quake leaves fewer errors at a cost of discarding more sequence.
\quorum outputs more reads that align perfectly to the finished sequence (see Table~\ref{table:perfect-reads}).

\end{abstract}



\ifthenelse{\boolean{publ}}{\begin{multicols}{2}}{}




%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%%                                          %%
%% The Main Body begins here                %%
%%                                          %%
%% The Section headings here are those for  %%
%% a Research article submitted to a        %%
%% BMC-Series journal.                      %%  
%%                                          %%
%% If your article is not of this type,     %%
%% then refer to the instructions for       %%
%% authors on:                              %%
%% http://www.biomedcentral.com/info/authors%%
%% and change the section headings          %%
%% accordingly.                             %% 
%%                                          %%
%% See the Results and Discussion section   %%
%% for details on how to create sub-sections%%
%%                                          %%
%% use \cite{...} to cite references        %%
%%  \cite{koon} and                         %%
%%  \cite{oreg,khar,zvai,xjon,schn,pond}    %%
%%  \nocite{smith,marg,hunn,advi,koha,mouse}%%
%%                                          %%  
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%




%%%%%%%%%%%%%%%%
%% Background %%
%%
\section*{Background}
While second generation sequencing technologies have progressed tremendously and offer ever longer reads with low overall sequencing error rate, correcting errors in reads remains an important pre-processing step in \emph{de novo} genome assembly.
In general, error correcting the reads leads to assemblies with longer contiguous sequences and fewer misassemblies~\cite{Salzberg2011}.

For Illumina sequencing, the base quality degrades toward the 3' ends of the reads, therefore one can trim the reads either by a fixed amount or based on the quality values reported by the sequencing machine.
Although these simple trimming schemes will reduce the number of erroneous bases, it still leaves many errors in the reads and needlessly discards a lot of valid sequence. 
Aggressive trimming results in fragmented assemblies.

On the other hand, trimming can be an integral part of error correction.
The distribution of sequencing errors on the reads is complex and for some percentage of the reads, the sequence beyond a certain point contains too many errors to be corrected or, even worse, does not correspond to any sequence in the original genome.
It is important to trim those reads to avoid misassemblies~\cite{Salzberg2011}.

%% I still think a paragraph explaining why error correction is even
%% possible is necessary.
% Genomes are sequenced at some depth.
% Meaning that every part of the genome should be present in more than one sequencing read.
% As sequencing machines make a mistake reading a base, this error can be detected by comparing the read to others covering the same region of the genome.
% Put another way, erroneous base should follow a different probability distribution than correct bases.

There is a number of published error correctors that use different techniques to detect and correct these erroneous bases~\cite{Yang2012}.
Coral~\cite{salmela2011correcting} and Echo~\cite{Kao2011} use multiple alignment of the reads.
Then, a statistical model of sequencing is used to correct misaligned bases.
HiTec~\cite{Ilie2011b} uses a suffix array to find and correct potentially erroneous bases.
Quake~\cite{Kelley:2010fk} uses the distribution of $k$-mers, or the $k$-spectrum, to detect $k$-mers containing erroneous bases.
The first three error correctors only attempt to make base substitutions, while the last one, Quake, will also trim reads.

% We propose a new error correction procedure and software package, named \quorum (Quality Optimized Reads from the University of Maryland), that provides accurate trimming and error correction.
\quorum (Quality Optimized Reads from the University of Maryland) uses both the $k$-spectrum and the quality scores reported by the sequencing machine.
In addition, \quorum is flexible: it can correct reads of varying length and reads containing ambiguous base calls (Ns).
% TODOcheck number below
It is also fast (1 billion $\SI{100}{bases}$ long reads in a day) and can tackle the large data sets produced by today's high throughput sequencing machine.
QuorUM only corrects substitution errors, not insertions and deletions.
It is well suited for correcting reads sequenced using Illumina technology~\cite{Bentley2008}, where the substitutions errors are the most common.

We evaluate the error correction and trimming skill of QuorUM and compare it to  other published error correctors (HiTec, Echo, Coral and Quake), on  three genomes that have Illumina reads and have genome assemblies of finished quality.
We compare the error correctors by aligning the original reads and the error corrected reads to the finished sequence and measure the improvements.

% First, we report the number of substitution errors left after error correction and the number of new errors introduced (i.e.\@ false positive rate) (Table~\ref{table:left-introduced}).
% This measures how well the software corrects individual substitution errors.
% %
% Second, we measure the number of chimeric reads before and after error correction (Table~\ref{table:chimeric}).
% % Def chimeric has been added. Is this OK?
% A read is called chimeric if it does not match the finished genome in one piece but the read can be split into two parts that match the genome in two widely separated places.
% This measures the likelihood  of the software to over correct by gluing sequences that do not belong together.
% %
% Third, we report the amount of sequence which is error free reads (i.e.\@ reads which aligns perfectly to the finished sequence) (Table~\ref{table:perfect-reads}).
% These reads are easy for assemblers to use, and this is a measure of how well the correction and trimming work.
% %
% Fourth, we report the contig sizes of ``idealized contigs'' created by aligning error corrected reads to the finished sequence (Table~\ref{table:icontigs}).
% This procedure, similar to a guided assembly, provides some estimate of the maximum contig size achievable through assembly, without the bias of using a particular assembler.
% Finally, we will report the time and memory consumption to carry out the correction.

% We use the evaluation toolkit of~\cite{Yang2012} with some modifications (see~\ref{sec:Methods}).

 
%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%% Results and Discussion %%
%%
\section*{Results and Discussion}

We evaluated the error correction software by error correcting the reads of three organisms, two bacterial genomes and a mammalian genome, for which a finished sequence is available: \species{Rhodobacter sphareoides} (rhodobacter)~\cite{Mackenzie2001}, \species{Mus musculus} (mouse)~\cite{Waterston2002} and \species{Staphylococcus aureus} (staphylococcus).
These genomes present different type of challenges for error correction.
The \species{Rhodobacter sphaeroides} bacteria genome (\SI{4.6}{Mb} long) has a high GC content and is consequently difficult to sequence using Illumina technology.
The mouse genome, being a mammalian genome, is larger and more complex.
For the sake of simplicity, we only use chromosome 16 of the mouse genome which has \SI{98}{Mb} in finished sequence.

We were able to successfully run all five error correctors on the bacterial data sets.  
Echo and HiTEC failed on the larger mouse data.
In addition, we implemented two simple programs that only trim the input reads.
trim20B trims $20$ bases off the 3' end of the reads, while trimQual5 trims the 3' end of a read at a base where the quality goes below or equal to $5$ and subsequently never goes above $5$.
When applicable, we also compare the results to doing no correction at all, mentioned in the result tables as the ``none'' corrector.

A corrector can foul some of the reported metrics by very aggressively trimming the reads.
At the extreme, a corrector can trim every read to one base and, as a result, obtain only perfect reads.
More realistically, there is a trade-off between trimming off the hard to correct regions of the reads and attempting to correct these regions; a trade-off between the amount of sequence in the corrected reads and the quality of the sequence.
*As seen in Table~\ref{table:perfect-reads} and~\ref{table:left-introduced}, \quorum achieves a balance between aggressive trimming and accurate correction.

Table~\ref{table:perfect-reads} reports the number of reads and the total sequence in perfect corrected reads;
i.e.\@ corrected reads which have a full length error free alignment with the finished sequence.
\quorum consistently produces the largest number of perfect reads and the largest amount of sequence in perfect reads.
Although \quorum trims and discards some reads (see Table~\ref{table:left-introduced}), the amount of perfect sequence is larger than that produced by the correctors that do not trim or discard any reads, such as Echo, HiTEC and Coral.
Moreover, \quorum trims less aggressively than Quake while still producing a higher percentage of perfect reads.

We call a read \emph{chimeric} when it merges together sequences from two or more distant regions of the genome.
Such reads typically cannot be corrected, they have to be trimmed or discarded.
The Illumina technology generates few chimeric reads (usually less than $1\%$ of all the reads).
When doing very aggressive error correction, one runs the risk of creating new chimeric reads;
i.e.\@ sequence from a distant, possibly repeated, region of the genome is used to rewrite significant portion of a read.
Table~\ref{table:chimeric} shows that Quake and \quorum decrease significantly the number of chimeric reads.
HiTEC actually  increases the number of chimeric reads while Echo and Coral make only small decreases in chimeric reads.

For Table~\ref{table:left-introduced}, we record the sequencing errors in the reads by comparing the sequence of a reads to its best alignment against the finished sequence.
After error correction, we record which errors where corrected or not.
Although in practice error correction and trimming are done concurrently, Table~\ref{table:left-introduced} shows the results as if these two operations are done one after the other.
The second column shows the proportion of errors that are within the trim region and the third column shows proportion of these errors which are not corrected.
The fourth column shows the proportion of errors which are introduced by the correction routine (the False Positive rate).
The last column is the proportion of the errors left after trimming and correction over the total number of errors.

Quake leaves the fewest errors in the reads ($C_5$) but at the expense of very aggressive trimming (over $40\%$ of the reads on the bacterial genomes, see $C_1$).
\quorum discards a lot less sequence ($C_1$) while output reads with few errors ($C_5$).
Coral, Echo and HiTEC do not trim and are not very aggressive in the correction ($C_3$), hence the corrected reads still contain many errors.

%%%%%%%%%%%%%%%%%%%%%%
\section*{Conclusions}
Our goal in creating an error corrector is to aid in assembly of whole genome shotgun reads.
The results we produce are aimed at a partial evaluation of that goal.
Coral, Echo and HiTEC correct errors without trimming the reads, but some reads have so many errors at the 3' end that the reads cannot be corrected effectively.
These three correctors leave more errors than either Quake or \quorum (see column $C_5$ of Table~\ref{table:left-introduced}).
If an assembly project generates sufficiently deep coverage (e.g.\@ \cov{100}), then Quake's tendency to discard sequence (up to $42\%$ in our study) may not be a handicap.
Whether Quake or \quorum assists an assembly program to produce a better assembly may depend upon the particular assembly program, the depth of coverage and the idiosyncrasies of the genome being assembled.

  
%%%%%%%%%%%%%%%%%%
\section*{Methods}
\label{sec:Methods}

\subsection*{Correcting bases}
\label{sec:meth-error-correction}

% \quorum error corrects reads by replacing low quality $k$-mers in the input reads with high quality $k$-mers.
% The quality of a $k$-mer is based first on the quality values reported by the sequencing machine of the bases in the mer and second by its number of occurrences in the reads.

% \quorum uses the Jellyfish~\cite{Marcais2011} software to count the number of occurrences of the $k$-mers in the input reads.
% First it counts the occurrences of all $k$-mers and second it counts the occurrences $k$-mers in which all bases have a quality value greater than a threshold (by default $5$ above the minimum quality). We call the latter $k$-mers ``high quality''.
% Then, every read is examined in turn.
% \quorum searches for an \emph{anchor} $k$-mer: a $k$-mer whose number of occurrences is higher than a threshold $a$ ($a = 3$ by default). 
% Starting from this anchor, \quorum will look at every base, extending toward the 5' and 3' ends, and decide to make a correction based on the $k$-mer ending at that base.
% Let $m = xb$ bet the $k$-mer, where $|m| = k$, $x$ is a prefix with $|x| = k - 1$, and $b$ is the base under consideration.
% If $m$ has a number of occurrences greater than $a$, then no correction is made.
% Otherwise, the 3 possible alternatives $b'$ are considered.
% \quorum considers in priority the $k$-mers $m' = xb'$ in the high-quality set.
% Only if all $m'$ have count 0 in the high-quality set is the set containing all $k$-mers considered.
% \quorum substitutes base $b$ by $b'$ if only one of the alternative has a occurrence count at least 3 times that of $m$.
% Moreover, \quorum checks that this substitution is not a dead-end.
% I.e.\@ that at least one the of four extensions of $m'$ is present in the input reads, where the extensions of $m'$ are the four possible $k$-suffixes of $m'b''$ and $b''$ is a base.

% {\bf Correcting a base in a read.}
We designed QuorUM algorithm to produce error corrected reads that are most useful for de novo assembly and mapping.
We based our algorithm on the following observations.
First, the base quality is the best at the 5' end, and it degrades towards the 3' end of the reads.
Second, the read coverage is not uniform, there are biases, for example due to CG content of the sequencing fragments and other reasons.
Therefore the low $k$-mer counts are not always indicative of errors in those $k$-mers.
We classify $k$-mers in the reads based on their max-min quality as follows.
For any $k$-mer $m$, i.e. a given string of $k$ bases, an instance of $m$ (call it $m_i$) is the occurrence of the sequence of $m$ in a read, associated with $k$ quality scores.
The max-min quality of $m$ is the maximum over all instances $m_i$ of $m$ of the minimum of the quality scores of $m_i$.
If the max-min quality is above a certain threshold $q$, we call the $k$-mer reliable.
In other words, a $k$-mer is reliable if there exists at least one instance of $m$ where all bases have a quality score of at least $q$.

\quorum error corrects reads by replacing low quality $k$-mers in the input reads with high quality $k$-mers.
It uses Jellyfish~\cite{Marcais2011} to create a database of the reliable $k$-mers and all $k$-mers.
\quorum first look for an \emph{anchor}: a group of reliable $k$-mers with counts above a threshold close to the 5' end of the reads.
The size of the group and the count threshold ($a$) are parameters to \quorum.
Starting from this anchor, \quorum will look at every base, extending in turn toward the 5' and 3' ends.
Here we consider extension toward the 3' end and leave the reverse to the reader.
As \quorum shifts the $k$-mer toward the 3' end one base at a time, it and decides whether to make a correction based on the $k$-mer ending at that base.
Let $m = xb$ be the anchor $k$-mer, where the length $|m| = k$, and $x$ is a prefix with length $|x| = k - 1$, and $b$ is the base under consideration.
If $m$ has a number of occurrences greater than $a$ in the entire database, then no correction is made; otherwise, the 3 possible alternative bases $b'$ are considered.
\quorum determines if any of the three $k$-mers $m' = xb'$ are in the high-quality set.
Only if all three $m'$ have count 0 in the high-quality set is the set containing all $k$-mers considered.
\quorum substitutes base $b'$ for $b$ if only one of the alternative $xb'$ considered has an occurrence count at least 3 times that of $m$.
Moreover, \quorum checks that this substitution is not a dead-end; i.e.\@ at least one the of four extensions of $m'$ is present in the input reads, where the extensions of $m'$ are the four possible $k$-suffixes of $m'b''$ and $b''$ is a base.
If there were two base errors in a row, \quorum would be very unlikely to make a change. 

\subsection*{Trimming}
\label{sec:meth-trimming}
The maximum number of corrections made in a window of length $10$ is by default capped at $3$.
\quorum will trim the read at the beginning of the window if the number of errors is higher.

% These options were not used in the work on this paper. Yes or No???
% The first option was not used. The second one was the Rhodobacter data.
In addition, \quorum has two extra optional procedure for trimming reads. 
It takes as input a set of contaminant $k$-mers and it will trim a read wherever it contains such a contaminant mer.

Also, in high or low GC genome, the Illumina sequencers tend to erroneously generate long homo-polymer run toward the 3' end of the reads.
\quorum can optionally detect and trim off these homo-polymer.


\subsection*{Evaluation}

The reads for \species{S. aureus} have accessions SRR022868.
The finished sequence is version USA300\_TCH1516.
The genome is $\SI{2.9}{Mb}$ in length.
There are $5\,176\,416$ reads of length $\SI{101}{bases}$, for a coverage of $\cov{180}$.

The reads for \species{R. sphaeroides} have accessions SRR081522.
The finished sequence is version 2.4.1.
The genome is $\SI{4.6}{Mb}$ in length.
There are  reads of length $\SI{101}{bases}$, for a coverage of $\cov{43}$.

The reads for the \species{M. musculus} have accessions SRR067634, SRR067650, SRR067648, SRR067622, SRR067649, SRR067641, SRR067670, SRR067636, SRR067612, SRR067616, SRR067615, SRR067623, SRR067605, SRR067646, SRR067633, SRR067620, SRR067606, SRR067611, SRR067625, SRR067601, SRR067624, SRR067645, SRR067635, SRR067653, SRR067607, SRR067669, SRR067603, SRR067660, SRR067619, SRR067658, SRR067604, SRR067631, SRR067639, SRR067657, SRR067610, SRR067654, SRR067644, SRR067618, SRR067652, SRR067663, SRR067823, SRR067839, SRR067846, SRR067858, and SRR067830.
The finished sequence is UCSC's mm10 build.
For this evaluation, we use only chromosome 16, $\SI{98.2}{Mb}$ in length.
We aligned all the reads to all the chromosomes with the bowtie2 aligner and selected any read pair that has an alignment to chromosome 16 consistent with the library length within $5$ standard deviations.
We instructed bowtie2 to consider up to $5$ seeds (switch {\tt -R 5}) and to report the best out of $6$ alignments (switch {\tt -M 5}).
Also, we consider partial alignments (switch {\tt --local}).

%% 1Somewhat inaccurate. The error correctors will attempt to error
%% correct the reads with no alignment. They are just not used in the
%% ratios of the first table.
% The purpose of the study is to see what fraction of the errors are eliminated.
% That requires us to match the original reads against the finished sequence for each of the three genomes in order to determine how many errors the original reads have.
% Some reads have enough errors that the aligner could not match them against the finished sequence.
% These reads were eliminated from the study and all results ignore the deleted reads.
% In particular, the fractions of reads eliminated before the study began were $8.9\%$ for \species{R. sphaeroides}, $15.6\%$ for \species{S.aureus} and $2.5\%$ for \species{M. musculus}.

%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\section*{Authors contributions}
G.M. provided the implementation of Quorum and performed the evaluation.
A.Z. provided code improvements.
All the authors contributed to the development of the algorithm, writing of the manuscript and approved it for publication.

    

%%%%%%%%%%%%%%%%%%%%%%%%%%%
\section*{Acknowledgements}
  \ifthenelse{\boolean{publ}}{\small}{ }
The authors were supported by grant ...


 
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%%                  The Bibliography                       %%
%%                                                         %%              
%%  Bmc_article.bst  will be used to                       %%
%%  create a .BBL file for submission, which includes      %%
%%  XML structured for BMC.                                %%
%%                                                         %%
%%                                                         %%
%%  Note that the displayed Bibliography will not          %% 
%%  necessarily be rendered by Latex exactly as specified  %%
%%  in the online Instructions for Authors.                %% 
%%                                                         %%
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%


{
  \ifthenelse{\boolean{publ}}{\footnotesize}{\small}
  \bibliographystyle{bmc_article}  % Style BST file
  \bibliography{bmc_article}
}     % Bibliography file (usually '*.bib' ) 

%%%%%%%%%%%

\ifthenelse{\boolean{publ}}{\end{multicols}}{}

%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%%                               %%
%% Figures                       %%
%%                               %%
%% NB: this is for captions and  %%
%% Titles. All graphics must be  %%
%% submitted separately and NOT  %%
%% included in the Tex document  %%
%%                               %%
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%

%%
%% Do not use \listoffigures as most will included as separate files

% \section*{Figures}
% \subsection*{Figure 1 - Sample figure title}
% A short description of the figure content
% should go here.

% \subsection*{Figure 2 - Sample figure title}
% Figure legend text.



%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%%                               %%
%% Tables                        %%
%%                               %%
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%

% \newrobustcmd{\bnum}[1]{\bfseries #1}

%% Use of \listoftables is discouraged.
%%
\newcounter{tablecounter}
\newcommand{\tabledesc}[1]{%
\refstepcounter{tablecounter}%
\subsection*{Table \thetablecounter\  - #1}%
}
%% Winner number in a table
\newcommand{\winner}[1]{\bfseries #1}
\newcommand{\tn}[1]{S[detect-weight,table-format=#1]}

\section*{Tables}
\robustify\bfseries


\tabledesc{Perfect output reads and bases as percent of input.}
\label{table:perfect-reads}

A perfect read is a read (possibly trimmed) that aligns with no error on its full length to the finish sequence.
This table reports in the ``Reads'' column the number of perfect error-corrected reads as a proportion of the number of original reads (with an alignment to the finished sequence).
The ``Sequence'' column displays the number of bases in perfect error-corrected reads as a proportion of the number of bases in original reads (with an alignment to the finished sequence).
These ratios ignore the original reads which do not align at all.

Because in the input data, all the reads have the same length ($\approx \SI{100}{bases}$), the two columns are equal for the correctors that do not trim the reads.

\bigskip

\begin{tabular}{@{}lS[detect-weight,table-format=2.1]S[detect-weight,table-format=2.1]S[detect-weight,table-format=2.1]S[detect-weight,table-format=2.1]S[detect-weight,table-format=2.1]S[detect-weight,table-format=2.1]@{}}
\toprule
Corrector & \multicolumn{2}{c}{Rhodobacter} & \multicolumn{2}{c}{Staphylococcus} &\multicolumn{2}{c}{Mouse}                      \\
\cmidrule(rl){2-3} \cmidrule(rl){4-5} \cmidrule(l){6-7}
{}        & {Reads (\%)}  & {Sequence (\%)} & {Reads (\%)}  & {Sequence (\%)} & {Reads (\%)}  & {Sequence (\%)} \\
\midrule                                                                                                       
none      & 20.9          & 20.9            & 33.1          & 33.1            & 48.3          & 48.3            \\
trim20B   & 44.4          & 35.6            & 46.3          & 37.2            & 79.4          & 63.6            \\
trimQual5 & 76.2          & 51.2            & 35.3          & 35.1            & 78.0          & 71.9            \\
coral     & 58.2          & 58.2            & 73.5          & 73.5            & 80.9          & 80.9            \\
echo      & 56.3          & 56.3            & 65.1          & 65.1            &               &                 \\
hitec     & 60.8          & 60.8            & 77.9          & \winner{77.9}   &               &                 \\
% quakedk   & 61.9          & 48.5            &               &                 &               &                 \\
quake     & 80.5          & 58.9            & 68.2          & 57.6            & 88.7          & 81.3            \\
\quorum   & \winner{90.2} & \winner{68.2}   & \winner{84.8} & 69.8            & \winner{90.9} & \winner{86.9}   \\
\bottomrule
\end{tabular}

%
%
\tabledesc{Chimeric reads}

\label{table:chimeric}

% Jim: We have to make sure that our definitions agree with what I put in the main text. Two distinct pieces allows one to be extremely small and it does not say that the whole read is the union of the two pieces.
A chimeric read is defined here as a read that does not align in one piece while it has two disjoint subsequences that align to far apart regions of the finished sequence. 
The table shows the number of chimeric reads after error correction.
``None'' denote the number without any error correction.

\bigskip

\begin{tabular}{@{}lS[detect-weight,table-format=4]S[detect-weight,table-format=4]S[detect-weight,table-format=6]@{}}
\toprule
{Corrector} & {Rhodobacter} & {Staphylococcus} & {Mouse}        \\
\midrule                                                       
none        & 2086          & 733              & 296772         \\
trim20B     & 1655          & 597              & 250382         \\
trimQual5   & 649           & 720              & 148439         \\
coral       & 2047          & 1024             & 225052         \\
echo        & 1809          & 704              &                \\
hitec       & 6375          & 1200             &                \\
quake       & 61            & 651              & \winner{63079} \\
quorum      & \winner{46}   & \winner{35}      & 93158          \\
\bottomrule
\end{tabular}

%
%
\tabledesc{Errors in output including introduced errors}
\label{table:left-introduced}

The ``Bases trimmed'' is the percentage of bases in trimmed reads compared with bases in the original reads.
All the bases in a discarded read count as bases trimmed off.
The ``Errors not trimmed from reads'' is the percentage of errors in the trimmed reads compared with the errors in the original reads.
The ``errors left in trimmed reads'' is the percentage of errors in the corrected reads compared with the errors in the trimmed reads.
The ``Errors introduced'' is the number of errors introduced divided by the number of errors in the original reads.
These are counted in the previous column ``errors left in trimmed reads''.
Finally, the ``Errors in corrected trimmed reads'' is the percentage of errors in corrected reads compared with the errors in the original reads.
If $C_i$ is the value in the $i$-th column, then following holds: $C_2 \cdot C_3 = C_5$.

For a corrector that does not trim, then $C_1 = 0.0$ (no bases trim) and $C_2 = 100$ (all the original errors are left because of the absence of trimming).
A pure trimmer has $C_3 = 100$ (no correction made) and $C_4 = 0$ (no error introduced).

\bigskip

\begin{tabular}{@{}lS[detect-weight,table-format=2.1]S[detect-weight,table-format=3.1]S[detect-weight,table-format=2.2]S[detect-weight,table-format=2.1]S[detect-weight,table-format=2.1]@{}}
\toprule
          & 1          & 2                    & 3                   & 4               & 5                        \\
\cmidrule{2-6}
{}        & {\% bases} & {\% errors not}      & {\% of errors left} & {\% errors}     & {\% errors in corrected} \\
Corrector & {trimmed}  & {trimmed from reads} & {in trimmed reads}  & {introduced}    & {trimmed reads}          \\
\midrule
{}        & \multicolumn{5}{c}{Rhodobacter}                                                                      \\
\cmidrule{2-6} 
trim20B   & 19.8       & 43.9                 & 100                 & 0.00            & 43.9                     \\
trimQual5 & 36.0       & 11.2                 & 100                 & 0.00            & 11.2                     \\
coral     & 0.00       & 100                  & 77.7                & 0.766           & 77.7                     \\
echo      & 0.00       & 100                  & 65.1                & 2.11            & 65.1                     \\
hitec     & 0.00       & 100                  & 61.1                & 10.4            & 61.1                     \\
% quakedk & 30.6       & 81.5                 & 98.2                & 0.365           & 80.1                     \\ 
quake     & 40.6       & \winner{2.06}        & 16.6                & \winner{0.0473} & 0.342                    \\ 
quorum    & 31.2       & 14.7                 & \winner{2.13}       & 0.0669          & \winner{0.314}           \\
\cmidrule{2-6}
{}        & \multicolumn{5}{c}{Staphylococcus}                                                                   \\
\cmidrule{2-6}
trim20B   & 19.8       & 53.8                 & 100                 & 0.00            & 53.8                     \\
trimQual5 & 1.30       & 91.7                 & 100                 & 0.00            & 91.7                     \\
coral     & 0.00       & 100                  & 52.8                & 1.08            & 52.8                     \\
echo      & 0.00       & 100                  & 38.6                & 0.628           & 38.6                     \\
hitec     & 0.00       & 100                  & 21.3                & 1.57            & 21.3                     \\
quake     & 42.0       & \winner{13 .7}       & 4.98                & 0.115           & 0.682                    \\
quorum    & 29.8       & 42.1                 & \winner{1.14}       & \winner{0.0882} & \winner{0.478}           \\
\cmidrule{2-6}
{}        & \multicolumn{5}{c}{Mouse}                                                                            \\
\cmidrule{2-6}
trim20B   & 19.8       & 29.0                 & 100                 & 0.00            & 29.0                     \\
trimQual5 & 10.5       & 28.0                 & 100                 & 0.00            & 28.0                     \\
coral     & 0.00       & 100                  & 69.0                & 12.5            & 69.0                     \\
quake     & 14.2       & \winner{10.4}        & 71.5                & \winner{.494}   & \winner{7.40}            \\
quorum    & 6.75       & 29.4                 & \winner{34.7}       & .786            & 10.2                     \\
\bottomrule
\end{tabular}

%
%

%
%


%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%%                               %%
%% Additional Files              %%
%%                               %%
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%

% \section*{Additional Files}
% \subsection*{Additional file 1 --- Sample additional file title}
% Additional file descriptions text (including details of how to
% view the file, if it is in a non-standard format or the file extension).  This might
% refer to a multi-page table or a figure.

% \subsection*{Additional file 2 --- Sample additional file title}
% Additional file descriptions text.


\end{bmcformat}
\end{document}








% LocalWords:  QuORUM HiTEC misassemblies Illumina Rhodobacter
% LocalWords:  contigs
