text: user383: I have often downloaded datasets from the SRA where the authors failed to mention which adapters were trimmed during the processing.
  Local alignments tend to overcome this obstacle, but it feels a bit barbaric.
  fastQC works occasionally to pick them up, but sometimes fails to find the actual adapter sequences.
  Usually, I ended up looking up the kits they used and trying to grep for all the possible barcodes.
  Is there a more robust/efficient way to do this?
  
  user292: If you happen to know a sequence that should be highly abundant in the library, you can grep its beginning or end (with pattern match highlighting) and see if the same sequence systematically comes just before or just after respectively. This kind of visual inspection can help you finding the adaptor.
  For instance, in a previous lab, we were working on D. melanogaster small RNA sequencing data and my colleague knew from previous experience with this kind of data that the following small RNA was likely to be abundant: http://flybase.org/reports/FBgn0065042.html
  We just had to grep it in the fastq file to see many lines with this sequence, next to another sequence that happened to be always the same: the unknown adapter.
  
  user306: The minion utility from the kraken/reaper toolkit may be helpful for this: http://wwwdev.ebi.ac.uk/enright-dev/kraken/reaper/src/reaper-latest/doc/minion.html
  
  user73: I'm not aware of any existing methods to do this, but here are a couple of ideas about how it might be done:
  Canu has a method of adapter trimming which involves looking for the absence of overlap for reads. If there are no other reads which share sequence across a particular region, then the read is broken up at the point of low coverage, and small pieces are discarded. It would be possible to use a method like this to hunt for possible adapter/barcode sequences by preserving the short reads.
  Another option is to do a kmer search at the start of reads, and see if any of the high-abundance kmers can be assembled together and/or matched to existing known adapters or barcodes.
  
  user224: You mention that FastQC "fails to find the actual adapter sequences" - I guess you mean in the Adapter Sequence Contamination plot. However, the kmer and Sequence Content Plots are often useful even when the former fails. I've used these in the past - you can sometimes just read off the adapter sequence from the start of the Sequence Content Plot (or at least see how many bases to trim).
  
original_text: 383: <p>I have often downloaded datasets from the SRA where the authors failed to mention which adapters were trimmed during the processing.</p>
  
  <p>Local alignments tend to overcome this obstacle, but it feels a bit barbaric.</p>
  
  <p>fastQC works occasionally to pick them up, but sometimes fails to find the actual adapter sequences.</p>
  
  <p>Usually, I ended up looking up the kits they used and trying to grep for all the possible barcodes.</p>
  
  <p>Is there a more robust/efficient way to do this?</p>
   292: <p>If you happen to know a sequence that should be highly abundant in the library, you can grep its beginning or end (with pattern match highlighting) and see if the same sequence systematically comes just before or just after respectively. This kind of visual inspection can help you finding the adaptor.</p>
  
  <p>For instance, in a previous lab, we were working on <em>D. melanogaster</em> small RNA sequencing data and my colleague knew from previous experience with this kind of data that the following small RNA was likely to be abundant: <a href="http://flybase.org/reports/FBgn0065042.html" rel="nofollow noreferrer">http://flybase.org/reports/FBgn0065042.html</a></p>
  
  <p>We just had to grep it in the fastq file to see many lines with this sequence, next to another sequence that happened to be always the same: the unknown adapter.</p>
   306: <p>The <code>minion</code> utility from the kraken/reaper toolkit may be helpful for this: <a href="http://wwwdev.ebi.ac.uk/enright-dev/kraken/reaper/src/reaper-latest/doc/minion.html" rel="nofollow noreferrer">http://wwwdev.ebi.ac.uk/enright-dev/kraken/reaper/src/reaper-latest/doc/minion.html</a></p>
   73: <p>I'm not aware of any existing methods to do this, but here are a couple of ideas about how it might be done:</p>
  
  <p>Canu has a method of adapter trimming which involves looking for the absence of overlap for reads. If there are no other reads which share sequence across a particular region, then the read is broken up at the point of low coverage, and small pieces are discarded. It would be possible to use a method like this to hunt for possible adapter/barcode sequences by preserving the short reads.</p>
  
  <p>Another option is to do a kmer search at the start of reads, and see if any of the high-abundance kmers can be assembled together and/or matched to existing known adapters or barcodes.</p>
   224: <p>You mention that FastQC <em>"fails to find the actual adapter sequences"</em> - I guess you mean in the Adapter Sequence Contamination plot. However, the kmer and Sequence Content Plots are often useful even when the former fails. I've used these in the past - you can sometimes just read off the adapter sequence from the start of the Sequence Content Plot (or at least see how many bases to trim).</p>
  