mapping/samtools_sort

Description

Sort and (optionally) index alignments.

Reads are sorted by leftmost coordinates, or by read name when --sort_by_read_names is used.

An appropriate @HD-SO sort order header tag will be added or an existing one updated if necessary.

Note that to generate an index file (by specifying --output_bai), the default coordinate sort must be used.
Thus the --sort_by_read_names and --sort_by <TAG> options are incompatible with --output_bai.

Type

python_script

License

MIT

Contributors

Run this component

Run the following command to execute this component with Nextflow:

cat > params.yaml <<'EOM'  
output_bam: "$id.$key.output_bam.bam"  
output_bai: "$id.$key.output_bai.bai"  
id: "run"  
publish_dir: "output/"  
EOM

nextflow run https://packages.viash-hub.com/vsh/openpipeline.git \  
  -revision 2.1.2 \  
  -main-script target/nextflow/mapping/samtools_sort/main.nf \  
  -params-file params.yaml  

Input

Name
Type & Properties
--input
file
required

Output

Name
Type & Properties
--output_bam
file
required
output
--output_bai
file
output
--output_format
string
--compression
integer

Arguments

Name
Type & Properties
--minimizer_cluster
boolean_true
--minimizer_kmer
integer
--sort_by_read_names
boolean_true
--sort_by
string
--no_pg
boolean_true

Collaborate Accelerate Succeed

Empower your organization with secure, scalable workflow solutions that simplify development, ensure compliance, and drive innovation.

Viash Hub is a platform developed by Data Intuitive, a Belgian-based bioinformatics company specializing in data workflow development and deployment.