Hello,
I'm wondering if anyone knows whether there is a tool for clustering sequences that have already been aligned? Something that doesn't mind the unaligned hyphens and takes into consideration gaps "----AGSM----". Like usearch, something that might be able to specify the percentage identiy cutoff for the clustering, as well as the percentage of sequence alignment length (so it can cater for substrings). I have a concatenated alignment of marker genes that I am wanting to reduce to a representative set (based on 95% aai).
Thanks!
2 answers
Clustering an aligned set of sequences can easily be performed in R using the DECIPHER package:
library(DECIPHER)
aa <- readAAStringSet("<<PATH TO ALIGNMENT>>")
d <- DistanceMatrix(aa)
c <- IdClusters(d, method="complete", cutoff=0.05)
head(c)
This will give you cluster numbers at 95% identity on a complete-linkage tree. You can also specify other methods like "UPGMA".
I hope that helps!
Clustal Omega can take a multiple sequence alignment as input and output clusters.
EDIT: You can also output the distance matrix or pairwise identity matrix and use them for clustering using different algorithms. Check the docs.
Log in to answer this question.
Just a comment - it's helpful to others to specify "Amino Acid" or "Nucleotide" in the title, as well as "Multiple Sequence Alignments" rather than just "Alignments".