1samtools-split(1) Bioinformatics tools samtools-split(1)
2
3
4
6 samtools split - splits a file by read group.
7
9 samtools split [options] merged.sam|merged.bam|merged.cram
10
11
13 Splits a file by read group, producing one or more output files match‐
14 ing a common prefix (by default based on the input filename) each con‐
15 taining one read-group.
16
17 The -u option may be used to specify the output filename for any
18 records without an RG tag.
19
20
22 -u FILE1 Put reads with no RG tag or an unrecognised RG tag into
23 FILE1
24
25 -h FILE2 Use the header from FILE2 when writing the file given in
26 the -u option. This header completely replaces the one
27 from the input file. It must be compatible with the in‐
28 put file header, which means it must have the same number
29 of references listed in the @SQ lines and the references
30 must be in the same order and have the same lengths.
31
32 -f STRING Output filename format string (see below) ["%*_%#.%."]
33
34 -v Verbose output
35
36 --no-PG Do not add a @PG line to the header of the output file.
37
38 Format string expansions:
39
40 %% %
41 %* basename
42 %# @RG index
43 %! @RG ID
44 %. output format filename extension
45
46 -@, --threads INT
47 Number of input/output compression threads to use in addition to
48 main thread [0].
49
50
52 Written by Martin Pollard from the Sanger Institute.
53
54
56 samtools(1), samtools-addreplacerg(1)
57
58 Samtools website: <http://www.htslib.org/>
59
60
61
62samtools-1.13 7 July 2021 samtools-split(1)