Crates.io | filter-clipped |
lib.rs | filter-clipped |
version | 0.3.0 |
source | src |
created_at | 2022-08-07 13:18:12.484538 |
updated_at | 2023-01-29 21:51:06.93739 |
description | A bam/sam util to filter out highly clipped NGS reads from alignment files |
homepage | |
repository | |
max_upload_size | |
id | 640213 |
size | 48,295 |
[Rust learning project]
Remove alignments with high number of clipped base.
Sometimes aligners have very loose scoring methods and write alignments with high abundant of soft/hard-clipped base into alignment BAM files. This program is for filtering these reads out by gating the number of clipped bases in relative to the read sequence length
$ git clone https://github.com/wckdouglas/filter-clipped
$ cd filter-clipped
$ cargo install --path . # if compilation error, try CC=/usr/bin/gcc cargo install --path .
$ filter-clipped --help
filter-clipped 0.1.0
Remove alignments with high number of clipped base. Sometimes aligner has very loose scoring methods
and write alignments with high abundant of soft/hard-clipped base into alignment BAM files. This
program is for filtering these reads out by gating the number of clipped bases in relative to the
read sequence length
USAGE:
filter-clipped [OPTIONS] --in-bam <IN_BAM>
OPTIONS:
-b, --both-end <BOTH_END> maximum fraction of total bases on the sequence being clipped
[default: 0.1]
-h, --help Print help information
-i, --in-bam <IN_BAM> input bam file path ("-" for stdin)
--inverse keeping the failed ones (high-clipped-fraction alignments)
-l, --left-side <LEFT_SIDE> maximum fraction of bases on the sequence being clipped from
the left side (5' end) [default: 0.1]
-o, --out-bam <OUT_BAM> output bam file path ("-" for stdout) [default: -]
-r, --right-side <RIGHT_SIDE> maximum fraction of bases on the sequence being clipped from
the right side (3' end) [default: 0.1]
-V, --version Print version information
cargo test
docker pull ghcr.io/wckdouglas/filter-clipped:main
docker run --env RUST_LOG=info -v $PWD/:/root/ ghcr.io/wckdouglas/filter-clipped:main --in-bam /root/bamfile_in_current_path.bam | samtools view