bpipe
bpipe copied to clipboard
Regex splitting documentation
Hi Simon,
Every time I use a new feature of bpipe, I'm trying to put my experience into words to help you with documentation:
Splitting input files using wildcards: run { "%_*.fastq.gz" * [ align_bwa ] }
Splitting input files using regular expressions: Let's say my sample names contain underscores for example: pool18_tag3_1.fastq.gz pool18_tag3_2.fastq.gz The sample name is "pool18_tag3" and "1" or "2" indicates forward and reverse reads respectively. It becomes necessary to use a regular expression. Use "~" to indicate you are using regular expressions. Your regex should include the part matching the sample name in (). For example. run { ~"(.*?)_[12].fastq.gz" * [ align_bwa ] }
This works in bpipe-0.9.8.6_rc, but may be available earlier
Warm regards, Harriet