title: Snakemake using multi inputs
body: <p>I'm starting to write a pipeline for my bioinformatics project and I'm using the Snakemake as workflow.
  I made all the tutorial of the official site and I some of the documentation.</p>
  
  <p>I want to run a single shell command, like that:
  <code><b>fastp -i</b> input-1 <b>-I</b> input-2 <b>-o</b> output-1 <b>-O</b> output-2</code></p>
  
  <p>My code in Snakefile:</p>
  
  <pre><code>SAMPLES = ['1', '2', '3', '4']
  rule fastp:
      input:
          reads1=expand("sample{sample}.R1.fq.gz", sample=SAMPLES),
          reads2=expand("sample{sample}.R2.fq.gz", sample=SAMPLES)
      output:
          reads1out=expand("sample{sample}.R1.fq.gz.out", sample=SAMPLES),
          reads2out=expand("sample{sample}.R2.fq.gz.out", sample=SAMPLES)
      shell:
          "fastp -i {input.reads1} -I {input.reads2} -o {output.reads1out} -O {output.reads2out}"
  </code></pre>
  
  <p>But the program run this single line of code:<code>
  <b>fastp -i</b> sample1.R1.fq.gz sample2.R1.fq.gz sample3.R1.fq.gz sample4.R1.fq.gz <b>-I</b> sample1.R2.fq.gz sample2.R2.fq.gz sample3.R2.fq.gz sample4.R2.fq.gz <b>-o</b> sample1.R1.fq.gz.out sample2.R1.fq.gz.out sample3.R1.fq.gz.out sample4.R1.fq.gz.out <b>-O</b> sample1.R2.fq.gz.out sample2.R2.fq.gz.out sample3.R2.fq.gz.out sample4.R2.fq.gz.out
  </code></p>
  
  <p>How can I write the program to do a different shell command for each sample? I tried a <code>for i in SAMPLES:</code> after the <code>rule fastp:</code> but doesn't worked and I don't know what I can try now. Sorry if this topic is too basic in some way, but I'm a noob in Python.</p>
  
  <p>Thank you. </p>