# Strain Identity Cutoff

**URL:** <https://forum.biobakery.org/t/strain-identity-cutoff/1094>\
**Category:** StrainPhlAn\
**Created:** [September 30, 2020, 2:37pm UTC](https://forum.biobakery.org/t/strain-identity-cutoff/1094 "2020-09-30T14:37:58Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![cazzlewazzle89](https://yyz1.discourse-cdn.com/flex027/user_avatar/forum.biobakery.org/cazzlewazzle89/32/317_2.png) [@cazzlewazzle89](https://forum.biobakery.org/u/cazzlewazzle89)\
**Post date:** [September 30, 2020, 2:37pm UTC](https://forum.biobakery.org/t/strain-identity-cutoff/1094/1 "2020-09-30T14:37:58Z")

</div>

Hi All,

I have ran my samples through StrainPhlAn3 and calculated distance matrices using Emboss (with Kimura correction as per the tutorial).

My question is whether there is a consensus on what to use as an identity cutoff when looking to see if the same strain is present in two different samples? Should I look for a distance of zero or should this be relaxed to allow for sequencing errors?

Thanks in advance,  
Calum

---

<div class="post-metadata">

**Author:** ![aitor.blancomiguez](https://yyz1.discourse-cdn.com/flex027/user_avatar/forum.biobakery.org/aitor.blancomiguez/32/86_2.png) [@aitor.blancomiguez](https://forum.biobakery.org/u/aitor.blancomiguez)\
**Post date:** [September 30, 2020, 3:09pm UTC](https://forum.biobakery.org/t/strain-identity-cutoff/1094/2 "2020-09-30T15:09:47Z")

</div>

Hi @cazzlewazzle89,  
If you are interested in detect the same strain in different samples I would suggest you to use the normalized phylogenetic distances retrieved from the branch lenghts of the phylogenetic tree (normalizing the branch distances by the total branch length). In terms of the cutoff, this will slightly differ depending on the species you are interested on, but 0.01 would be a good approximation ([https://www.nature.com/articles/s41467-020-18127-y#Sec4](https://www.nature.com/articles/s41467-020-18127-y#Sec4))

Best,  
Aitor

---

<div class="post-metadata">

**Author:** ![cazzlewazzle89](https://yyz1.discourse-cdn.com/flex027/user_avatar/forum.biobakery.org/cazzlewazzle89/32/317_2.png) [@cazzlewazzle89](https://forum.biobakery.org/u/cazzlewazzle89)\
**Post date:** [September 30, 2020, 3:38pm UTC](https://forum.biobakery.org/t/strain-identity-cutoff/1094/3 "2020-09-30T15:38:17Z")

</div>

Thanks Aitor 😄

---

<div class="post-metadata">

**Author:** ![cazzlewazzle89](https://yyz1.discourse-cdn.com/flex027/user_avatar/forum.biobakery.org/cazzlewazzle89/32/317_2.png) [@cazzlewazzle89](https://forum.biobakery.org/u/cazzlewazzle89)\
**Post date:** [October 1, 2020, 8:53am UTC](https://forum.biobakery.org/t/strain-identity-cutoff/1094/4 "2020-10-01T08:53:01Z")

</div>

Hi @aitor.blancomiguez

Thanks again for the reply. As a follow up question:  
By _total branch length_ do you mean the sum of all edges in the tree or the sum of branch length from all tips to the root?  
I have also seen another normalisation method suggested based on dividing the phylogenetic distance between each pair of leaves by the median of these distances.

All the best,  
Calum

---

<div class="post-metadata">

**Author:** ![aitor.blancomiguez](https://yyz1.discourse-cdn.com/flex027/user_avatar/forum.biobakery.org/aitor.blancomiguez/32/86_2.png) [@aitor.blancomiguez](https://forum.biobakery.org/u/aitor.blancomiguez)\
**Post date:** [October 2, 2020, 9:56am UTC](https://forum.biobakery.org/t/strain-identity-cutoff/1094/5 "2020-10-02T09:56:49Z")

</div>

Hi @cazzlewazzle89  
I meant the sum of all the branch lengths in the tree. If you are using Python, you could use the **total\_branch\_length()** function of the _Phylo.BaseTree_ included in _Biopython_: [https://biopython.org/docs/1.75/api/Bio.Phylo.BaseTree.html#Bio.Phylo.BaseTree.TreeMixin.total\_branch\_length](https://biopython.org/docs/1.75/api/Bio.Phylo.BaseTree.html#Bio.Phylo.BaseTree.TreeMixin.total_branch_length)  
For the other normalisation method using the mean value, that will also work ([https://www.sciencedirect.com/science/article/pii/S1931312818303172](https://www.sciencedirect.com/science/article/pii/S1931312818303172))

Best,  
Aitor
