'\" t .TH samtools-fqidx 1 "22 September 2020" "samtools-1.11" "Bioinformatics tools" .SH NAME samtools fqidx \- Indexes or queries regions from a fastq file .\" .\" Copyright (C) 2008-2011, 2013-2018, 2020 Genome Research Ltd. .\" Portions copyright (C) 2010, 2011 Broad Institute. .\" .\" Author: Heng Li .\" Author: Joshua C. Randall .\" .\" Permission is hereby granted, free of charge, to any person obtaining a .\" copy of this software and associated documentation files (the "Software"), .\" to deal in the Software without restriction, including without limitation .\" the rights to use, copy, modify, merge, publish, distribute, sublicense, .\" and/or sell copies of the Software, and to permit persons to whom the .\" Software is furnished to do so, subject to the following conditions: .\" .\" The above copyright notice and this permission notice shall be included in .\" all copies or substantial portions of the Software. .\" .\" THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR .\" IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, .\" FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL .\" THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER .\" LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING .\" FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER .\" DEALINGS IN THE SOFTWARE. . .\" For code blocks and examples (cf groff's Ultrix-specific man macros) .de EX . in +\\$1 . nf . ft CR .. .de EE . ft . fi . in .. . .SH SYNOPSIS .PP samtools fqidx .IR ref.fastq " [" region1 " [...]]" .SH DESCRIPTION .PP Index reference sequence in the FASTQ format or extract subsequence from indexed reference sequence. If no region is specified, .B fqidx will index the file and create .I .fai on the disk. If regions are specified, the subsequences will be retrieved and printed to stdout in the FASTQ format. The input file can be compressed in the .B BGZF format. The sequences in the input file should all have different names. If they do not, indexing will emit a warning about duplicate sequences and retrieval will only produce subsequences from the first sequence with the duplicated name. .B samtools fqidx should only be used on fastq files with a small number of entries. Trying to use it on a file containing millions of short sequencing reads will produce an index that is almost as big as the original file, and searches using the index will be very slow and use a lot of memory. .SH OPTIONS .TP 8 .BI "-o, --output " FILE Write FASTQ to file rather than to stdout. .TP .BI "-n, --length " INT Length of FASTQ sequence line. [60] .TP .B -c, --continue Continue working if a non-existent region is requested. .TP .BI "-r, --region-file " FILE Read regions from a file. Format is chr:from-to, one per line. .TP .B -i, --reverse-complement Output the sequence as the reverse complement. When this option is used, \*(lq/rc\*(rq will be appended to the sequence names. To turn this off or change the string appended, use the .B --mark-strand option. .TP .B --mark-strand TYPE Append strand indicator to sequence name. TYPE can be one of: .RS .TP .B rc Append '/rc' when writing the reverse complement. This is the default. .TP .B no Do not append anything. .TP .B sign Append '(+)' for forward strand or '(-)' for reverse complement. This matches the output of \*(lqbedtools getfasta -s\*(rq. .TP .B custom,, Append string to names when writing the forward strand and when writing the reverse strand. Spaces are preserved, so it is possible to move the indicator into the comment part of the description line by including a leading space in the strings and . .RE .TP .B --fai-idx FILE Read/Write to specified index file. .TP .B --gzi-idx FILE Read/Write to specified compressed file index (used with .gz files). .TP .B -h, --help Print help message and exit. .SH AUTHOR .PP Written by Heng Li, with modifications by Andrew Whitwham and Robert Davies, all from the Sanger Institute. .SH SEE ALSO .IR samtools (1), .IR samtools-faidx (1), .IR samtools-fasta (1), .IR samtools-fastq (1) .PP Samtools website: