# Output Lists of OTUs for Each Group in Separate Files

**URL:** <https://forum.mothur.org/t/output-lists-of-otus-for-each-group-in-separate-files/20699>\
**Category:** Commands in mothur\
**Created:** [September 21, 2020, 7:41pm UTC](https://forum.mothur.org/t/output-lists-of-otus-for-each-group-in-separate-files/20699 "2020-09-21T19:41:17Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![jbreil](https://avatars.discourse-cdn.com/v4/letter/j/96bed5/32.png) [@jbreil](https://forum.mothur.org/u/jbreil)\
**Post date:** [September 21, 2020, 7:41pm UTC](https://forum.mothur.org/t/output-lists-of-otus-for-each-group-in-separate-files/20699/1 "2020-09-21T19:41:17Z")

</div>

Hello,

I am currently looking through the commands and trying to figure out the best command to use to output a fasta or list for each group, that contains all of the OTU’s present within that group. Is the only way to do this to use get.otus for each group individually, or can this be achieved with some other command that I am missing?

Any advice is appreciated!

---

<div class="post-metadata">

**Author:** ![westcott](https://yyz2.discourse-cdn.com/flex036/user_avatar/forum.mothur.org/westcott/32/18_2.png) [@westcott](https://forum.mothur.org/u/westcott)\
**Post date:** [September 28, 2020, 5:46pm UTC](https://forum.mothur.org/t/output-lists-of-otus-for-each-group-in-separate-files/20699/2 "2020-09-28T17:46:36Z")

</div>

You can use the split.groups command, [https://mothur.org/wiki/split.groups/](https://mothur.org/wiki/split.groups/).

mothur \> split.groups(fasta=yourFastaFile, list=yourListFile, count=yourCountFile) - creates a \*.fasta, \*.list and \*.count file for each group

---

<div class="post-metadata">

**Author:** ![system](https://yyz2.discourse-cdn.com/flex036/user_avatar/forum.mothur.org/system/32/2_2.png) [@system](https://forum.mothur.org/u/system)\
**Post date:** [October 8, 2020, 5:46pm UTC](https://forum.mothur.org/t/output-lists-of-otus-for-each-group-in-separate-files/20699/3 "2020-10-08T17:46:44Z")

</div>

Closed on October 8, 2020, 5:46pm UTC

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