To parser a BAM header:
- In
methods.config
, include thebam_parser.config
file and callbam_parser.parse_bam_header(</path/to/bam>)
The function returns a Map
, with the following information:
read_group
: A list ofMaps
, where eachMap
contains one parsed read group from the BAM header.
parse_bam_header
- Function for parsing a BAM header- Positional args:
position name type required default description 1 bam_path
String Yes none String representing path to BAM file for parsing
- Positional args:
To load a BAM header from a file defined at params.bam_file_path
:
includeConfig "/path/to/bam_parser.config"
...
methods {
...
bam_header = bam_parser.parse_bam_header(params.bam_file_path)
}