# Working with FeatureData\[Sequence\] in Jupyter

**URL:** https://forum.qiime2.org/t/working-with-featuredata-sequence-in-jupyter/32701
**Category:** Technical Support
**Tags:** artifact-api, python-api
**Created:** [March 7, 2025, 10:49am UTC](https://forum.qiime2.org/t/working-with-featuredata-sequence-in-jupyter/32701 "2025-03-07T10:49:24Z")
**Posts on this page:** 5
**Page:** 1

<div class="post-metadata">

### Author: ![vimh](https://forum.qiime2.org/letter_avatar_proxy/v4/letter/v/e47c2d/32.png) [@vimh](https://forum.qiime2.org/u/vimh)
#### Post date: [March 7, 2025, 10:49am UTC](https://forum.qiime2.org/t/working-with-featuredata-sequence-in-jupyter/32701/1 "2025-03-07T10:49:24Z")

</div>

Hello!

I'm just moving from command line to q2-api via jupyter notebook. The issue I'm facing right now is related to my need to see the repseqs (FeatureData[Sequence]) produced by dada2 in a pd.DataFrame.

After considering the classical strategy of a visualizer, I chose to have this information contained in a pd.DataFrame because I want to explore some things by my own and I need the info to be easily accesible. I tried using repseqs.view(pd.DataFrame) but it cannot be done. The error is:  
Exception: No transformation from \<class 'q2\_types.feature\_data.\_formats.DNASequencesDirectoryFormat'\> to \<class 'pandas.core.frame.DataFrame'\>

The main question is: How can I do to charge the repseqs in a dataframe? But it would be also good to know if there is a place where it is defined the available transformations from each data type. I've been digging in the github repository but I couldn´t find anything. Maybe there is other repository with more documentation?

Even if I was able to have the sequences in a pd.DataFrame, is it possible to return this information to an Artifact in order to continue with my workflow (i.e taxonomy assignment)?

Thank you very much!  
Víctor

---

<div class="post-metadata">

### Author: ![jwdebelius](https://forum.qiime2.org/user_avatar/forum.qiime2.org/jwdebelius/32/9655_2.png) [@jwdebelius](https://forum.qiime2.org/u/jwdebelius)
#### Post date: [March 7, 2025, 3:06pm UTC](https://forum.qiime2.org/t/working-with-featuredata-sequence-in-jupyter/32701/2 "2025-03-07T15:06:40Z")

</div>

Hi @vimh,

You can view the sequences as a pd.Series and then turn the series into a data frame:

```auto
seqs_q2 = Artifact.load('rep-seqs.qza')
seqs = seqs_q2.view(pd.Series)
seqs.to_frame()

```

You can 100% turn a series of sequences back into an Artifact.

I agree, it would be nice to have more documentation of transforms.

Best,  
Justine

---

<div class="post-metadata">

### Author: ![vimh](https://forum.qiime2.org/letter_avatar_proxy/v4/letter/v/e47c2d/32.png) [@vimh](https://forum.qiime2.org/u/vimh)
#### Post date: [March 11, 2025, 10:17am UTC](https://forum.qiime2.org/t/working-with-featuredata-sequence-in-jupyter/32701/3 "2025-03-11T10:17:40Z")

</div>

Thanks @jwdebelius, now I can continue with my workflow. Maybe it is a simple thing but without help I could not.

Best,  
Víctor

---

<div class="post-metadata">

### Author: ![jwdebelius](https://forum.qiime2.org/user_avatar/forum.qiime2.org/jwdebelius/32/9655_2.png) [@jwdebelius](https://forum.qiime2.org/u/jwdebelius)
#### Post date: [March 11, 2025, 9:05pm UTC](https://forum.qiime2.org/t/working-with-featuredata-sequence-in-jupyter/32701/4 "2025-03-11T21:05:21Z")

</div>

Hi @vimh,

Glad we could help!

And I will say that I was either told by someone (Evan? Matt? Liz? Tomasz? IDK) or else read the code to find hte transformer, which is non-trivial.

Best,  
Justine

---

<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: [April 12, 2025, 3:06am UTC](https://forum.qiime2.org/t/working-with-featuredata-sequence-in-jupyter/32701/5 "2025-04-12T03:06:03Z")

</div>

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