Last active
July 1, 2016 18:54
snakemake-paired-sample
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
aDict = {"B":"inputG1", "A":"inputG1", "C":"inputG2"} | |
rule all: | |
input: ["C.bed", "A.bed", "B.bed"] | |
def get_files(wildcards): | |
case = wildcards.case | |
control = aDict[case] | |
return [case + ".sorted.bam", control + ".sorted.bam"] | |
rule call_peak: | |
input: get_files | |
output: "{case}.bed" | |
run: | |
case = input[0] | |
control = input[1] | |
shell("echo macs14 -t {case} -c {control} -n {wildcards.case}") | |
shell("touch {output}") |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# read https://groups.google.com/forum/#!searchin/snakemake/dependencies/snakemake/iDnr3PIcsfE/x-qQvzWBBgAJ | |
# https://groups.google.com/forum/#!searchin/snakemake/dependencies/snakemake/1QelazgzilY/oBgZoP19BL4J | |
aDict = {"B":"inputG1", "A":"inputG1", "C":"inputG2"} | |
rule all: | |
input: ["C.bed", "A.bed", "B.bed"] | |
def get_files(wildcards): | |
case = wildcards.case | |
control = aDict[case] | |
return [case + ".sorted.bam", control + ".sorted.bam"] | |
rule call_peak: | |
input: get_files | |
output: "{case}.bed" | |
shell: | |
""" | |
echo macs14 -t {input[0]} -c {input[1]} -n {wildcards.case} | |
touch {output} | |
""" |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment