# qiime moshpit bin-contigs-metabat: FeatureData\[MAG\] nowhere to be found

**URL:** https://forum.qiime2.org/t/qiime-moshpit-bin-contigs-metabat-featuredata-mag-nowhere-to-be-found/30955
**Category:** Technical Support
**Tags:** moshpit
**Created:** [July 26, 2024, 2:31pm UTC](https://forum.qiime2.org/t/qiime-moshpit-bin-contigs-metabat-featuredata-mag-nowhere-to-be-found/30955 "2024-07-26T14:31:33Z")
**Posts on this page:** 6
**Page:** 1

<div class="post-metadata">

### Author: ![pietervanveelen](https://forum.qiime2.org/user_avatar/forum.qiime2.org/pietervanveelen/32/19014_2.png) [@pietervanveelen](https://forum.qiime2.org/u/pietervanveelen)
#### Post date: [July 26, 2024, 2:31pm UTC](https://forum.qiime2.org/t/qiime-moshpit-bin-contigs-metabat-featuredata-mag-nowhere-to-be-found/30955/1 "2024-07-26T14:31:33Z")

</div>

Dear @misialq and @Nicholas_Bokulich lab,

When binning contigs using qiime moshpit bin-contigs-metabat, the output produced for --o-mags are of type SampleData[MAGs]. However, for dereplicating MAGs and for classifying MAGs using 'qiime moshpit classify-kraken2' a FeatureData[MAG] type is required instead. browsing through your tutorials and help files, I am unable to find how to find or create the FeatureData[MAG] artifact. What I did see in my temp dir was a hash directory for every MAG created, and the data folder contains a fast format file. I suspect this is the data I am looking for. I am wondering why this is still in temp, and not output as FeatureData[MAG]. Are they unfinished somehow?

Happy to hear from you on how you advise me to proceed.

Cheers,  
Pieter

---

<div class="post-metadata">

### Author: ![misialq](https://forum.qiime2.org/user_avatar/forum.qiime2.org/misialq/32/9053_2.png) [@misialq](https://forum.qiime2.org/u/misialq)
#### Post date: [July 29, 2024, 2:28pm UTC](https://forum.qiime2.org/t/qiime-moshpit-bin-contigs-metabat-featuredata-mag-nowhere-to-be-found/30955/2 "2024-07-29T14:28:19Z")

</div>

Hey @pietervanveelen,

great question, thanks! So the idea is that the `SampleData[MAGs]` represents non-dereplicated MAGs (straight from binning) and `FeatureData[MAG]` then corresponds to the dereplicated ones. The dereplicating action which we implemented for now in q2-moshpit can accept any `DistanceMatrix` representing similarity between all the MAGs in the `SampleData` artifact - we then use that similarity to find the non-redundant set of MAGs. This is not yet really documented anywhere but one way to obtain such a matrix is by using [sourmash](https://sourmash.readthedocs.io/en/latest/) through its QIIME 2 plugin - you can then use it as input to the dereplicate action. If you want to see the steps involved in this process, you can check out our semi-official tutorial [here](https://cap-lab.bio/q2-books/04-MAG-analysis.html#mags-dereplication-optional).

Let me know if you need more information 🙂

Cheers,  
Michal

---

<div class="post-metadata">

### Author: ![pietervanveelen](https://forum.qiime2.org/user_avatar/forum.qiime2.org/pietervanveelen/32/19014_2.png) [@pietervanveelen](https://forum.qiime2.org/u/pietervanveelen)
#### Post date: [July 30, 2024, 12:51pm UTC](https://forum.qiime2.org/t/qiime-moshpit-bin-contigs-metabat-featuredata-mag-nowhere-to-be-found/30955/3 "2024-07-30T12:51:50Z")

</div>

Hello @misialq,

Thanks, that is very helpful. I'll get onto trying that soon.  
I'm gonna bug you about another moshpit request, but I'll create another topic for it.

Best,  
Pieter

---

<div class="post-metadata">

### Author: ![Mechah](https://forum.qiime2.org/user_avatar/forum.qiime2.org/mechah/32/7261_2.png) [@Mechah](https://forum.qiime2.org/u/Mechah)
#### Post date: [August 2, 2024, 12:19pm UTC](https://forum.qiime2.org/t/qiime-moshpit-bin-contigs-metabat-featuredata-mag-nowhere-to-be-found/30955/4 "2024-08-02T12:19:36Z")

</div>

If sourmash is the recommended way to go, it would be great to include it in future core distributions of qiime2-metagenome...

---

<div class="post-metadata">

### Author: ![lizgehret](https://forum.qiime2.org/user_avatar/forum.qiime2.org/lizgehret/32/17128_2.png) [@lizgehret](https://forum.qiime2.org/u/lizgehret)
#### Post date: [August 2, 2024, 7:26pm UTC](https://forum.qiime2.org/t/qiime-moshpit-bin-contigs-metabat-featuredata-mag-nowhere-to-be-found/30955/5 "2024-08-02T19:26:15Z")

</div>

Hi @Mechah,

Jumping in for @misialq here! This is currently in the works, and we are hoping to have q2-sourmash included in the metagenome distribution for the 2024.10 release. 🙂

Cheers 🦎

---

<div class="post-metadata">

### Author: ![system](https://forum-qiime2-org.s3.dualstack.us-west-2.amazonaws.com/original/3X/2/1/21af5fe23cb6f4579467c66a9ed94e55274ca7bd.svg) [@system](https://forum.qiime2.org/u/system)
#### Post date: [September 3, 2024, 1:27am UTC](https://forum.qiime2.org/t/qiime-moshpit-bin-contigs-metabat-featuredata-mag-nowhere-to-be-found/30955/6 "2024-09-03T01:27:01Z")

</div>

This topic was automatically closed 31 days after the last reply. New replies are no longer allowed.
