diff --git a/README.md b/README.md index c26cd51..be16aba 100644 --- a/README.md +++ b/README.md @@ -69,7 +69,7 @@ Optional arguments: --window_length INT This parameter sets the length of a sliding window. (Default: 200) --step INT This parameter sets the number of positions to slide the window forward. (Default: 100) --percentage INT Threshold in percent (Default: 0) - --max_bp_between INT If footprints are less than X bases appart the footprints will be merged (Default: 6) + --min_gap INT If footprints are less than X bases apart the footprints will be merged (Default: 6) Filter motifs: --min_size_fp INT Minimum sequence length threshold. Smaller sequences are discarded. (Default: 10) diff --git a/pipeline.nf b/pipeline.nf index 0ca6c7d..dcab67a 100644 --- a/pipeline.nf +++ b/pipeline.nf @@ -16,7 +16,7 @@ params.window_length = 200 params.step = 100 params.percentage = 0 - params.max_bp_between = 6 + params.min_gap = 6 //filter_unknown_motifs params.min_size_fp=10 @@ -46,6 +46,7 @@ params.motif_min_key = 8 // Minimum number of key positions (aligned columns) params.motif_max_key = 20 // Maximum number of key positions (aligned columns) params.iteration = 10000 // Number of Iterations done by glam2. A high iteration number equals a more accurate result but with an higher runtime. + params.gap_penalty = 1000 //tomtom params.tomtom_treshold = 0.01 // threshold for similarity score. @@ -86,7 +87,7 @@ Optional arguments: --window_length INT This parameter sets the length of a sliding window. (Default: 200) --step INT This parameter sets the number of positions to slide the window forward. (Default: 100) --percentage INT Threshold in percent (Default: 0) - --max_bp_between INT If footprints are less than X bases appart the footprints will be merged (Default: 6) + --min_gap INT If footprints are less than X bases apart the footprints will be merged (Default: 6) Filter motifs: --min_size_fp INT Minimum sequence length threshold. Smaller sequences are discarded. (Default: 10) @@ -114,6 +115,7 @@ Optional arguments: --iteration INT Number of iterations done by GLAM2. More Iterations: better results, higher runtime. (Default: 10000) --tomtom_treshold FLOAT Threshold for similarity score. (Default: 0.01) --best_motif INT Get the best X motifs per cluster. (Default: 3) + --gap_penalty INT Set penalty for gaps in GLAM2 (Default: 1000) Moitf clustering: --cluster_motif Boolean If 1 pipeline clusters motifs. If its 0 it does not. (Defaul: 0) --edge_weight INT Minimum weight of edges in motif-cluster-graph (Default: 5) @@ -141,7 +143,7 @@ int_params = ["window_length", "step", "min_size_fp", "max_size_fp", "kmer", "aprox_motif_len", "motif_occurence", "min_seq_length", "global", "sequence_coverage", "memory", "throw_away_seq", "strand", "min_seq", "motif_min_key", "motif_max_key", "iteration", - "edge_weight", "best_motif"] + "edge_weight", "best_motif", "min_gap", "gap_penalty", "edge_weight"] req_params = ["bigwig", "bed", "genome_fasta", "motif_db", "config"] valid_organism = ["hg38", "hg19", "mm9", "mm10"] @@ -212,7 +214,7 @@ process footprint_extraction { script: """ - python ${path_bin}/1.1_footprint_extraction/footprints_extraction.py --bigwig ${bigWig} --bed ${bed} --output_file ${name}_called_peaks.bed --window_length ${params.window_length} --step ${params.step} --percentage ${params.percentage} --max_bp_between ${params.max_bp_between} + python ${path_bin}/1.1_footprint_extraction/footprints_extraction.py --bigwig ${bigWig} --bed ${bed} --output_file ${name}_called_peaks.bed --window_length ${params.window_length} --step ${params.step} --percentage ${params.percentage} --min_gap ${params.min_gap} """ } @@ -375,7 +377,7 @@ process glam2 { script: """ - glam2 n ${fasta} -O ./${name}/ -a ${params.motif_min_key} -b ${params.motif_max_key} -z 5 -n ${params.iteration} + glam2 n ${fasta} -O ./${name}/ -E ${params.gap_penalty} -J ${params.gap_penalty} -a ${params.motif_min_key} -b ${params.motif_max_key} -z 5 -n ${params.iteration} """ } @@ -541,7 +543,7 @@ process clustered_glam2 { script: name = fasta.getBaseName() """ - glam2 n ${fasta} -O ./${name}/ -a ${params.motif_min_key} -b ${params.motif_max_key} -z 5 -n ${params.iteration} + glam2 n ${fasta} -O ./${name}/ -E ${params.gap_penalty} -J ${params.gap_penalty} -a ${params.motif_min_key} -b ${params.motif_max_key} -z 5 -n ${params.iteration} """ }