text: user208: I want to align a short sequence to a reference, and both are encoded in the extended IUPAC notation (i.e. 16 letters).
  What alignment software can I use for that?
  For example, in Bowtie "all non-A/C/G/T characters in reads become Ns", so it ignores which extended letters are matching.
  
  user5077: You can try using Biostrings, depends on how large is your reference, if it is small, you can just pairwiseAlignment with the nucleotideSubstitutionMatrix which supposedly :
  library(Biostrings)
  data(phiX174Phage)
  
  x = DNAString("TCCAWRSCGCAGAAGT")
  
  lapply(phiX174Phage,function(y)pairwiseAlignment(x,y,
  substitutionMatrix = nucleotideSubstitutionMatrix()))
  
  $Genbank
  Global PairwiseAlignmentsSingleSubject (1 of 1)
  pattern: -------------TCCAWRSCGCAGAAGT...----------------------------
  subject: GAGTTTTATCGCTTCCATGACGCAGAAGT...TAAAAATGATTGGCGTATCCAACCTGCA
  score: -21491.92 
  
  $RF70s
  Global PairwiseAlignmentsSingleSubject (1 of 1)
  pattern: -------------TCCAWRSCGCAGAAGT...----------------------------
  subject: GAGTTTTATCGCTTCCATGACGCAGAAGT...TAAAAATGATTGGCGTATCCAACCTGCA
  score: -21491.92 
  
  $SS78
  Global PairwiseAlignmentsSingleSubject (1 of 1)
  pattern: -------------TCCAWRSCGCAGAAGT...----------------------------
  subject: GAGTTTTATCGCTTCCATGACGCAGAAGT...TAAAAATGATTGGCGTATCCAACCTGCA
  score: -21491.92 
  
  $Bull
  Global PairwiseAlignmentsSingleSubject (1 of 1)
  pattern: -------------TCCAWRSCGCAGAAGT...----------------------------
  subject: GAGTTTTATCGCTTCCATGACGCAGAAGT...TAAAAATGATTGGCGTATCCAACCTGCA
  score: -21491.92 
  
  $G97
  Global PairwiseAlignmentsSingleSubject (1 of 1)
  pattern: -------------TCCAWRSCGCAGAAGT...----------------------------
  subject: GAGTTTTATCGCTTCCATGACGCAGAAGT...TAAAAATGATTGGCGTATCCAACCTGCA
  score: -21491.92 
  
  $NEB03
  Global PairwiseAlignmentsSingleSubject (1 of 1)
  pattern: -------------TCCAWRSCGCAGAAGT...----------------------------
  subject: GAGTTTTATCGCTTCCATGACGCAGAAGT...TAAAAATGATTGGCGTATCCAACCTGCA
  score: -21491.92 
  
  If it is much larger, you can convert the sequence of interest to a pwm and find it in the reference fasta, like shown in this example
  
original_text: 208: <p>I want to align a short sequence to a reference, and both are encoded in the <a href="https://en.wikipedia.org/wiki/Nucleic_acid_notation" rel="nofollow noreferrer">extended IUPAC notation</a> (i.e. 16 letters).</p>
  
  <p>What alignment software can I use for that?</p>
  
  <p>For example, in <a href="http://bowtie-bio.sourceforge.net/bowtie2/news.shtml" rel="nofollow noreferrer">Bowtie</a> <em>"all non-A/C/G/T characters in reads become Ns",</em> so it ignores which extended letters are matching.</p>
   5077: <p>You can try using Biostrings, depends on how large is your reference, if it is small, you can just pairwiseAlignment with the nucleotideSubstitutionMatrix which supposedly :</p>
  
  <pre><code>library(Biostrings)
  data(phiX174Phage)
  
  x = DNAString("TCCAWRSCGCAGAAGT")
  
  lapply(phiX174Phage,function(y)pairwiseAlignment(x,y,
  substitutionMatrix = nucleotideSubstitutionMatrix()))
  
  $Genbank
  Global PairwiseAlignmentsSingleSubject (1 of 1)
  pattern: -------------TCCAWRSCGCAGAAGT...----------------------------
  subject: GAGTTTTATCGCTTCCATGACGCAGAAGT...TAAAAATGATTGGCGTATCCAACCTGCA
  score: -21491.92 
  
  $RF70s
  Global PairwiseAlignmentsSingleSubject (1 of 1)
  pattern: -------------TCCAWRSCGCAGAAGT...----------------------------
  subject: GAGTTTTATCGCTTCCATGACGCAGAAGT...TAAAAATGATTGGCGTATCCAACCTGCA
  score: -21491.92 
  
  $SS78
  Global PairwiseAlignmentsSingleSubject (1 of 1)
  pattern: -------------TCCAWRSCGCAGAAGT...----------------------------
  subject: GAGTTTTATCGCTTCCATGACGCAGAAGT...TAAAAATGATTGGCGTATCCAACCTGCA
  score: -21491.92 
  
  $Bull
  Global PairwiseAlignmentsSingleSubject (1 of 1)
  pattern: -------------TCCAWRSCGCAGAAGT...----------------------------
  subject: GAGTTTTATCGCTTCCATGACGCAGAAGT...TAAAAATGATTGGCGTATCCAACCTGCA
  score: -21491.92 
  
  $G97
  Global PairwiseAlignmentsSingleSubject (1 of 1)
  pattern: -------------TCCAWRSCGCAGAAGT...----------------------------
  subject: GAGTTTTATCGCTTCCATGACGCAGAAGT...TAAAAATGATTGGCGTATCCAACCTGCA
  score: -21491.92 
  
  $NEB03
  Global PairwiseAlignmentsSingleSubject (1 of 1)
  pattern: -------------TCCAWRSCGCAGAAGT...----------------------------
  subject: GAGTTTTATCGCTTCCATGACGCAGAAGT...TAAAAATGATTGGCGTATCCAACCTGCA
  score: -21491.92 
  </code></pre>
  
  <p>If it is much larger, you can convert the sequence of interest to a pwm and find it in the reference fasta, like shown in <a href="https://www.bioconductor.org/help/course-materials/2009/SeattleNov09/Biostrings/MatchAlign.pdf" rel="nofollow noreferrer">this example</a></p>
  