text: user1770: I have an MSA from MAFFT (as a FASTA file; there are several sequences in the MSA), and I would like to quantify the "variants" between these sequences.
  What is the standard tool to do something like this?
  I would prefer to know the non-consensus variants in the the entire MSA, but that may be too tricky, so I would like to figure out the non-consensus variants between those select sequences.
  I'm familiar with calculating an MSA, and then visualizing it---but I would like an output file with all of the different bases.
  
  user2459: A very basic solution in python:
  from Bio import SeqIO
  seq_dict = {i : rec.seq for i,rec in enumerate(SeqIO.parse("your_msa.aln", "fasta"))}
  for pos in range(len(seq_dict[0])):
      pos_bases = ([seqio[i] for seqio in [*seq_dict.values()]])
      # If position contains more than one unique base
      if len([*set(pos_bases)])>1:
          print(pos, pos_bases)        # prints the position and alternative bases there
  
  If you need something more useful, just leave a comment here and I'll develop this further.
  
original_text: 1770: <p>I have an MSA from MAFFT (as a FASTA file; there are several sequences in the MSA), and I would like to quantify the &quot;variants&quot; between these sequences.</p>
  <p>What is the standard tool to do something like this?</p>
  <p>I would prefer to know the non-consensus variants in the the entire MSA, but that may be too tricky, so I would like to figure out the non-consensus variants between those select sequences.</p>
  <p>I'm familiar with calculating an MSA, and then visualizing it---but I would like an output file with all of the different bases.</p>
   2459: <p>A very basic solution in python:</p>
  <pre class="lang-py prettyprint-override"><code>from Bio import SeqIO
  seq_dict = {i : rec.seq for i,rec in enumerate(SeqIO.parse(&quot;your_msa.aln&quot;, &quot;fasta&quot;))}
  for pos in range(len(seq_dict[0])):
      pos_bases = ([seqio[i] for seqio in [*seq_dict.values()]])
      # If position contains more than one unique base
      if len([*set(pos_bases)])&gt;1:
          print(pos, pos_bases)        # prints the position and alternative bases there
  </code></pre>
  <p>If you need something more useful, just leave a comment here and I'll develop this further.</p>
  