8
$\begingroup$

What is the index fastq file that comes with some Illumina sequencing datasets? (The samplename_I*.fastq.gz file.)

For example, I recently received some 10X Chromium reads for two libraries sequenced on the same lane. This was a 2x150 sequencing run, so there should be two fastq files. The sequencing center demultiplexed the libraries and generated two separate directories - one for each library.

  • In each directory there are three fastq files:
    • Mysample_I1_001.fastq.gz
    • Mysample_R1_001.fastq.gz
    • Mysample_R2_001.fastq.gz

I know that the R1 fastq file contains the forward reads and the R2 fastq file contains the reverse reads, but what is the index file? The first few sequences do not match the 10X indices for this library (ACATTACT, CAGCCCAC, GGCAATGG, TTTGGGTA).

>bioawk -cfastx '{print($seq)}' Mysample_I1_001.fastq.gz | head
NTTGGGTA
NGCAATGG
NAGCCCAC
NAGCCCAC
NCATTACT
NCATTACT
NGCAATGG
NAGCCCAC
NTTGGGTA
NAGCCCAC
$\endgroup$
  • 1
    $\begingroup$ I don't know 10x Chromium software, but I know their single cell pipeline, and many versions ago, the software was expecting the read indices to be in a separate file along with the reads themselves. Cellranger has since changed their pipeline so that it doesn't want these anymore, but whoever gave you your files might have seen that it was a 10xGenomics protocol, and decided to give you the indices like that just in case you needed them, $\endgroup$ – swbarnes2 Oct 8 '18 at 23:30
  • 2
    $\begingroup$ For what it's worth, 10X doesn't require the index files as input (you can just give it demultiplexed samples) and Illumina's software won't produce those index files by default. Also, you can have up to 2 index files for Illumina data (though you typically won't if you're making standard 10X libraries). $\endgroup$ – Devon Ryan Oct 9 '18 at 8:19
7
$\begingroup$

tldr - The I*.fastq.gz file contains the read index sequences.

long explanation

Illumina uses a program called bcl2fastq to demultiplex sequencing runs.

This software takes a list of samples and their associated indices and uses those sequences to make one or more fastq files per sample, binned by one or two index sequences on either end of the sequencing molecule (i5 and i7 indices, see page 6 for HiSeq).

Illumina sequencing isn't perfect though, and there are sometimes errors in reading the index sequence. For example this index, CAGCCCAC can easily have read errors in the A sandwiched between many Cs: CAGCCCAC -> CAGCCCCC.

Instead of throwing out all of the reads with indexing sequencing errors, the bcl2fastq program includes reads that are discernibly derived from a true index for that sample as long as there is no overlap with another sample.

In the example provided above, the four indices for mysample were: ACATTACT, CAGCCCAC, GGCAATGG, TTTGGGTA. If we look at all of the index sequences in the Mysample_I1_001.fastq.gz file, we will see that sequences with the four correct indices are indeed the most prevalent, however there are also reads that have indices with sequencing errors derived from the correct indices.

bioawk -cfastx '{print($seq)}' Mysample_I1_001.fastq.gz | \
    sort | uniq -c | sort -k1 -nr | head

count      index       source
41362311   CAGCCCAC    True index
37209190   GGCAATGG    True index
36863213   ACATTACT    True index 
33674467   TTTGGGTA    True index
 1140358   NAGCCCAC    CAGCCCAC
 1026099   NGCAATGG    GGCAATGG
 1016754   NCATTACT    ACATTACT
  933342   NTTGGGTA    TTTGGGTA
  119626   TTTGGGGA    TTTGGGTA
   98657   GTTGGGTA    TTTGGGTA
   96625   GGCAATGA    GGCAATGG
$\endgroup$
2
$\begingroup$

It took me a while to figure out that the "index" is the same thing as the "barcode" that says which sample each sequence is from on a multiplexed run.

If your data is not demultiplexed (single R1.fastq and R2.fastq files contain the information for multiple samples), then this I1.fastq file is what you use to assign each sequence to a sample (ie to "demultiplex"). The spreadsheet listing which barcode/index is which sample is often called a "mapping file."

If your data is already demultiplexed (you have separate R1.fastq and R2.fastq files for each sample), then you don't really need it... however some people use the index sequences in their quality control workflows. For example, this 2016 paper in BMC Genomics by Wright and Vetsigien "Quality filtering of Illumina index reads mitigates sample cross-talk": https://doi.org/10.1186/s12864-016-3217-x

$\endgroup$
  • 1
    $\begingroup$ The term index is almost always used to refer to the 8-bp sequence that the Illumina machine reads to identify the library-of-origin of the individual read, while the term barcode could also mean some sequence within R1 or R2 itself that the user added to label provenance - such as being from a specific cell or specific amplicon. $\endgroup$ – conchoecia Feb 12 at 14:19
  • $\begingroup$ Yes, in the context of a 10xGenomics single cell run, the "barcode" means the cell barcode, which is not at all the same thing as the sample index. $\endgroup$ – swbarnes2 Feb 12 at 17:31
  • $\begingroup$ I received 3 files that exactly match the file names listed by the original poster, except that my data was clearly not demultiplexed yet. My index file referred to what my mapping file listed as the "SampleBarcode". It's certainly possible that formats are different for single-cell data. For perspective, my data is from a multiplexed 16S rRNA gene amplicon miSeq run. My barcodes identified which sample each sequence was from, and they were a 12 bp sequence attached to the forward primer (so it was not dual-indexed). This is the protocol used by the Earth Microbiome Project. $\endgroup$ – rrr Feb 12 at 19:17
0
$\begingroup$

I looked at 10x data a couple of years ago, and at that time, their protocol would use four separate indexes, with balanced index sequences, as a way of introducing diversity into the library. These four indexes were separate from the individual oligos used to mark single cells. For an individual sample, you would need to combine the reads from all four separate indexes, which is how it looks like in your data. There is a brief explanation here: https://support.10xgenomics.com/single-cell-gene-expression/index/doc/specifications-sample-index-sets-for-single-cell-3

$\endgroup$

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.