2 ms·
snakemake does this trivially: rule analyze_country: input: 'whatever.{country}.txt' output: 'analysis.{country}.txt' shell:
by memoir2comment 8y ago
snakemake does this trivially:
rule analyze_country:
input: 'whatever.{country}.txt'
output: 'analysis.{country}.txt'
shell:
'run-analysis-on-country {input} {output} --country=country'
rule analyze_target_countries:
input: ['analysis.usa.txt', 'analysis.canada.txt', 'analysis.mexico.txt']
- elsherbini 8y agoSmall change, you have to use wilcards.country inside the shell call: rule analyze_country: input: 'whatever.{country}.txt' output: 'analysis.{country}.txt' shell: 'run-analysis-on-country {input} {output} --country={wildcards.country}'