Hi,

I am using FastQC and `EstimateLibraryComplexity` utility from Picard Tools to estimate the complexity of my paired-end RNAseq libraries. I have certain questions about the two tools.

First, according to the documentation of `EstimateLibraryComplexity`,

> Attempts to estimate library complexity from sequence of read pairs alone. Does so by sorting all reads by the first N bases (5 by default) of each read and then comparing reads with the first N bases identical to each other for duplicates. Reads are considered to be duplicates if they match each other with no gaps and an overall mismatch rate less than or equal to MAX_DIFF_RATE (0.03 by default).

So it uses a minimum of 5 bp identity to group reads together and using a max difference rate of 0.03 determines whether they are duplicates or not. Does that mean that if my read length is 100bp and the `MAX_DIFF_RATE` is 0.03, then it will assume reads to be duplicated unless they are different by more than 3 bp?

Second, how many bp does FastQC takes into consideration when determining duplicates? Is there an option in FastQC where you can change the minimum number of bases to be compared between reads in order for them to be considered duplicates.

Thanks!
> Does that mean that if my read length is 100bp and the MAX_DIFF_RATE is 0.03, then it will assume reads to be duplicated unless they are different by more than 3 bp?

Yes.

> Second, how many bp does FastQC takes into consideration when determining duplicates? Is there an option in FastQC where you can change the minimum number of bases to be compared between reads in order for them to be considered duplicates.

From the <a href="http://www.bioinformatics.babraham.ac.uk/projects/fastqc/Help/3%20Analysis%20Modules/8%20Duplicate%20Sequences.html">manual</a>:

> To cut down on the memory requirements for this module **only sequences which first appear in the first 200,000 sequences in each file are analysed**, but this should be enough to get a good impression for the duplication levels in the whole file. Each sequence is tracked to the end of the file to give a representative count of the overall duplication level. To cut down on the amount of information in the final plot any sequences with more than 10 duplicates are placed into grouped bins to give a clear impression of the overall duplication level without having to show each individual duplication value.

> Because the duplication detection requires an exact **sequence match over the whole length of the sequence**, any **reads over 75bp in length are truncated to 50bp** for the purposes of this analysis. Even so, longer reads are more likely to contain sequencing errors which will artificially increase the observed diversity and will tend to underrepresent highly duplicated sequences.