# Phyloseq to QIIME2

**URL:** https://forum.qiime2.org/t/phyloseq-to-qiime2/8703
**Category:** Other Bioinformatics Tools
**Tags:** import
**Created:** [March 8, 2019, 11:16pm UTC](https://forum.qiime2.org/t/phyloseq-to-qiime2/8703 "2019-03-08T23:16:50Z")
**Posts on this page:** 1
**Showing post:** 9

<div class="post-metadata">

### Author: ![ChristianEdwardson](https://forum.qiime2.org/user_avatar/forum.qiime2.org/christianedwardson/32/4215_2.png) [@ChristianEdwardson](https://forum.qiime2.org/u/ChristianEdwardson)
#### Post date: [March 12, 2019, 2:32am UTC](https://forum.qiime2.org/t/phyloseq-to-qiime2/8703/9 "2019-03-12T02:32:51Z")

</div>

OK I got your RDS containing the phyloseq object and examined it.

The reason it is failing is that part of my R function (phyloseq2qiime2) does a check for sequences (ATCG only) before writing a representative/reference sequence fasta file based on those sequences it finds either in the row names or column names (depending on if taxa\_are\_rows=TRUE or FALSE for your phyloseq object).

In your case, your phyloseq object contained both sequences _and_ MD5 hashes in the colnames. This is probably because you ran dada2 in QIIME2 for some of your samples, where the [default parameter](https://forum.qiime2.org/t/are-feature-ids-hashed-from-reads/1625) is `--p-hashed-feature-ids`. You can add the argument `--p-no-hashed-feature-ids` to output the ASV sequences instead of hashes.

Unfortunately, I don't have a fix for getting you a FASTA file right now using my script. The other files should be created correctly. If you need a FASTA file, can export a representative set of sequences from qiime2 and run `uniquesToFasta` from dada2 in R you could combine the two on the command line using `cat` and then filter for unique sequences using one of the various command line tools out there for FASTA file manipulation.

Hope this helps!  
Christian

---

_[View the full topic](https://forum.qiime2.org/t/phyloseq-to-qiime2/8703)._
