# Big differences in results depending on type of mapping used?

**URL:** <https://forum.biobakery.org/t/big-differences-in-results-depending-on-type-of-mapping-used/7282>\
**Category:** HUMAnN\
**Created:** [July 16, 2024, 6:59pm UTC](https://forum.biobakery.org/t/big-differences-in-results-depending-on-type-of-mapping-used/7282 "2024-07-16T18:59:24Z")\
**Posts on this page:** 6\
**Page:** 1

<div class="post-metadata">

**Author:** ![sjohnson](https://avatars.discourse-cdn.com/v4/letter/s/71c47a/32.png) [@sjohnson](https://forum.biobakery.org/u/sjohnson)\
**Post date:** [July 16, 2024, 6:59pm UTC](https://forum.biobakery.org/t/big-differences-in-results-depending-on-type-of-mapping-used/7282/1 "2024-07-16T18:59:24Z")

</div>

Hi all,

I’m trying to screen some metagenomics samples for nitrite reduction / NO-forming activity (see: [KEGG ENZYME: 1.7.2.1](https://www.genome.jp/entry/1.7.2.1)) using Humann3.6. If I check the samples for the two KOs listed on that web page, there’s very little evidence of NO-forming genes. K00368 seems present in a small % of samples:

```auto
$ grep "K00368" uniref90_ko.cpm.unstratified.tsv | cut -f1-30
K00368	0	0	0	0	0	0	0	0	0	0	0	0	0	0	0	0	0	0	0	0	0	0	0	0	1.35695	0	0	0	0

```

And K15864 appears to be entirely absent:

```auto
$ grep "K15864" uniref90_ko.cpm.unstratified.tsv
$

```

However if I look at the data by the E.C. entry (1.7.2.1), it appears to be both fairly abundant AND prevalent in the data:

```auto
$ grep "1\.7\.2\.1" uniref90_level4ec.cpm.unstratified.tsv | cut -f1-30
1.7.2.1	68.7	163.506	38.3125	160.131	99.7002	189.444	72.9189	79.5386	69.1712	0	143.998	0	94.3286	0	0	0	46.0324	96.4395	0	118.337	47.4957	8.24756	47.4995	49.5644	78.9407	103.753	99.8318	113.478	0

```

This would lead me to the opposite conclusion of the KO tables. Is there a reason why these results are so different? I would understand there being some minor differences but it seems to me that the different mappings should provide at least some level of consistency.

---

<div class="post-metadata">

**Author:** ![franzosa](https://yyz1.discourse-cdn.com/flex027/user_avatar/forum.biobakery.org/franzosa/32/3511_2.png) [@franzosa](https://forum.biobakery.org/u/franzosa)\
**Post date:** [July 16, 2024, 7:36pm UTC](https://forum.biobakery.org/t/big-differences-in-results-depending-on-type-of-mapping-used/7282/2 "2024-07-16T19:36:50Z")

</div>

We’ve seen recently that the KO annotations in UniRef90 are actually quite sparse, and that might be part of what’s going on here. My suspicion is that UniProt is only importing KO annotations from KEGG reference genomes, rather than doing _de novo_ KO prediction, hence you have to get somewhat lucky that the proteins you detect had KO annotations directly imported from KEGG. (Notably, as another user recently pointed out, UniProt appears to have stopped providing _any_ KO annotations in recent releases, opting instead to point KEGG reference sequences directly.)

Something we’ve been experimenting with internally is allowing KO annotations to be shared among UniRef90s that belong to the same UniRef50, which appears to boost KO annotation coverage quite a bit without loss of specificity. [Here is an expanded UniRef90-to-KO map based on this logic](https://www.dropbox.com/scl/fi/gzy25w7vsrzhr5jiq1o58/map_ko-expanded_uniref90.txt.gz?rlkey=5rcuv3pm0kk669ttw5gxp22vb&st=cgh36vb9&dl=0) that is compatible with the `humann_regroup_table` script. I’ll be curious to know if using this file instead of the default one improves agreement with your EC-focused result.

---

<div class="post-metadata">

**Author:** ![sjohnson](https://avatars.discourse-cdn.com/v4/letter/s/71c47a/32.png) [@sjohnson](https://forum.biobakery.org/u/sjohnson)\
**Post date:** [July 23, 2024, 7:27pm UTC](https://forum.biobakery.org/t/big-differences-in-results-depending-on-type-of-mapping-used/7282/3 "2024-07-23T19:27:33Z")

</div>

Thanks for providing that file, the results do seem to be in better agreement:

```auto
$ grep "K00368" uniref90_ko_NEW.cpm.unstratified.tsv | cut -f1-30
K00368	67.9994	110.217	42.1048	165.697	96.1491	85.9958	32.9454	67.5835	58.2956	0	0	0	16.5542	0	0	0	47.7426	36.4944	0	66.8156	36.0168	36.9052	49.0502	17.9201	62.3122	34.2248	99.2732	61.0391	0

```

I didn’t realize that the KO annotations were imported directly from UniRef rather than predicted _de novo_ – how feasible would something like this be? While there is a huge improvement with the new mapping file, I still would expect to see stronger agreement than this:

![image](https://canada1.discourse-cdn.com/flex027/uploads/biobakery/original/2X/6/6eab38b4865ea5946d436d4e265ff407236b7c98.png)

There’s a clear correlation, but there are a fair number of samples where either the KO or EC annotation is missing, or pretty far away from the diagonal

---

<div class="post-metadata">

**Author:** ![franzosa](https://yyz1.discourse-cdn.com/flex027/user_avatar/forum.biobakery.org/franzosa/32/3511_2.png) [@franzosa](https://forum.biobakery.org/u/franzosa)\
**Post date:** [August 2, 2024, 8:12pm UTC](https://forum.biobakery.org/t/big-differences-in-results-depending-on-type-of-mapping-used/7282/4 "2024-08-02T20:12:58Z")

</div>

Glad that helped (even if it wasn’t a perfect solution). Running the HMM-based KO predictions on all of UniRef90 is a pretty big compute. That said, we’re working on something like that for HUMAnN 4 since we have a lot of new proteins in that release that needed annotations.

---

<div class="post-metadata">

**Author:** ![adamsorbie](https://yyz1.discourse-cdn.com/flex027/user_avatar/forum.biobakery.org/adamsorbie/32/2099_2.png) [@adamsorbie](https://forum.biobakery.org/u/adamsorbie)\
**Post date:** [October 17, 2025, 10:24am UTC](https://forum.biobakery.org/t/big-differences-in-results-depending-on-type-of-mapping-used/7282/5 "2025-10-17T10:24:09Z")

</div>

Does a similar thing exist for UniRef50? I am having a similar issue using HUMANn v3.8 on mouse metagenomic data.

---

<div class="post-metadata">

**Author:** ![franzosa](https://yyz1.discourse-cdn.com/flex027/user_avatar/forum.biobakery.org/franzosa/32/3511_2.png) [@franzosa](https://forum.biobakery.org/u/franzosa)\
**Post date:** [November 4, 2025, 9:03pm UTC](https://forum.biobakery.org/t/big-differences-in-results-depending-on-type-of-mapping-used/7282/6 "2025-11-04T21:03:00Z")

</div>

Meaning expanded KO annotations? The file above should still work if you subset to the UniRef90s that are also UniRef50 representatives.
