bwaAlignment: bwaAlignment

Description Usage Arguments Examples

View source: R/bwaAlignment.R

Description

Aligns FASTQ files using bwa mem and a defined reference genome. It alignes fastq paired or single end data. The BAM to FASTQ conversion can be carried out using bamTofastqPicard function.

Usage

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
bwaAlignment(
  fastq,
  ref,
  out_path,
  threads,
  sambamba = "sambamba",
  bwa = "bwa",
  samblaster = "samblaster",
  samtools = "samtools"
)

Arguments

fastq

Fastq file to carry the analysis. If paried-end type, 'input_file' have to contain mate 1s and different pairs should be named "_R1" or "_R2". Allowed formats: fastq.gz, fq.gz, fastq, fq or bam.

ref

Path for the reference genome to use for the alignment (fasta format) and the corresponding indexes generated with bwa index and a dictionary index file generated by CreateSequenceDictionary gatk tool.

out_path

Path where the output of the analysis will be saved.

threads

Number of threads to use in the analysis.

sambamba

Path of sambamba binary

bwa

Path of bwa binary.

samblaster

Path of samblaster binary.

samtools

Path of samtools binary.

Examples

1
2
3
4
5
6
7
## Not run: 
bwaAlignment(fastq = 'raw/sample_R1.fa',
             ref = 'ref/hg38.fa',
             out_path = 'rst',
             threads = 2)

## End(Not run)

msubirana/ergWgsTools documentation built on June 8, 2020, 8:07 a.m.