Skip to content

Commit 6d04537

Browse files
committed
added regex patterns function
1 parent d0d81b8 commit 6d04537

File tree

1 file changed

+12
-1
lines changed

1 file changed

+12
-1
lines changed

workflow/scripts/general_functions.smk

+12-1
Original file line numberDiff line numberDiff line change
@@ -476,4 +476,15 @@ def check_consensus_peak_settings():
476476
subdirs = len([d for d in subdirs if os.path.isdir(d)])
477477

478478
if keep > subdirs:
479-
raise ValueError(f"Number of overlapping peaks to keep consensus peaks (config > consensus_peak > keep) is greater than number of subdirectories in reads/...")
479+
raise ValueError(f"Number of overlapping peaks to keep consensus peaks (config > consensus_peak > keep) is greater than number of subdirectories in reads/...")
480+
481+
482+
def regex_patterns():
483+
# Dictionary to store scaffold regex patterns
484+
patterns = {
485+
"hg38": r"^KI|^GL",
486+
"hg19": r"^GL",
487+
"mm39": r"^JH|^GL|^MU",
488+
"dm6": r"Scaffold|^\d{{15}}",
489+
}
490+
return patterns[resources.genome]

0 commit comments

Comments
 (0)