text: user2085: I have mapped some reads to a reference and want to change SNPs in the reference to SNPs found in the reads, even at low coverage. For example, here is a screenshot of one reference in IGV that I would like to correct. 
  
  When I use pilon to try to correct the reference, however, no bases are ever changed, even if using the option --mindepth 1.
  Here is the call that I am using:
  java -Xmx100G -jar {params.pilon}\
    --genome {input.ref}\
    --frags {input.bam}\
    --output {params.outname}\
    --changes --fix all,amb,breaks,bases\
    --threads {threads}\
    --mindepth 1
  
  How can I use even low-coverage information to correct my reference?
  
  user2085: Pilon will not consider fragments that are not proper pairs if the --frags option is used to pass the alignment .bam file. The reads mapped in the above IGV screenshot are unpaired.
  Instead, if you want Pilon to consider all reads that map as legitimate and usable for correction, pass the .bam file with the --unpaired option instead.
  To above corrected example would be:
  java -Xmx100G -jar {params.pilon}\
    --genome {input.ref}\
    --unpaired {input.bam}\
    --output {params.outname}\
    --changes --fix all,amb,breaks,bases\
    --threads {threads}\
    --mindepth 1
  
  
original_text: 2085: <p>I have mapped some reads to a reference and want to change SNPs in the reference to SNPs found in the reads, even at low coverage. For example, here is a screenshot of one reference in IGV that I would like to correct. </p>
  
  <p><a href="https://i.stack.imgur.com/zlUhX.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/zlUhX.png" alt="enter image description here"></a></p>
  
  <p>When I use pilon to try to correct the reference, however, no bases are ever changed, even if using the option <code>--mindepth 1</code>.</p>
  
  <p>Here is the call that I am using:</p>
  
  <pre><code>java -Xmx100G -jar {params.pilon}\
    --genome {input.ref}\
    --frags {input.bam}\
    --output {params.outname}\
    --changes --fix all,amb,breaks,bases\
    --threads {threads}\
    --mindepth 1
  </code></pre>
  
  <p>How can I use even low-coverage information to correct my reference?</p>
   2085: <p>Pilon will not consider fragments that are not proper pairs if the <code>--frags</code> option is used to pass the alignment <code>.bam</code> file. The reads mapped in the above IGV screenshot are unpaired.</p>
  
  <p>Instead, if you want Pilon to consider <em>all</em> reads that map as legitimate and usable for correction, pass the <code>.bam</code> file with the <code>--unpaired</code> option instead.</p>
  
  <p>To above corrected example would be:</p>
  
  <pre><code>java -Xmx100G -jar {params.pilon}\
    --genome {input.ref}\
    --unpaired {input.bam}\
    --output {params.outname}\
    --changes --fix all,amb,breaks,bases\
    --threads {threads}\
    --mindepth 1
  </code></pre>
  