# Issue with Group Files and Count.seqs Command in Mothur

**URL:** <https://forum.mothur.org/t/issue-with-group-files-and-count-seqs-command-in-mothur/22230>\
**Category:** Commands in mothur\
**Created:** [October 21, 2024, 5:04pm UTC](https://forum.mothur.org/t/issue-with-group-files-and-count-seqs-command-in-mothur/22230 "2024-10-21T17:04:49Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![JJOJ](https://avatars.discourse-cdn.com/v4/letter/j/c37758/32.png) [@JJOJ](https://forum.mothur.org/u/JJOJ)\
**Post date:** [October 21, 2024, 5:04pm UTC](https://forum.mothur.org/t/issue-with-group-files-and-count-seqs-command-in-mothur/22230/1 "2024-10-21T17:04:49Z")

</div>

I hope you’re doing well. I’m reaching out for assistance regarding persistent errors I’ve encountered when using Mothur for a metabarcoding analysis. I’ve been working through the pipeline in Aylagas et al. (2016) and encountered some problems, particularly when trying to generate a count table using the **count.seqs** command with my group file.

Context:

I’m currently analyzing 8 CO1 zooplankton samples from southwestern Puerto Rico using the NOAA Atlas database (North Atlantic CO1 reference). Everything works smoothly up to the point where I try to run **count.seqs** with my **.groups** file, which was generated using the **make.groups** command (following Aylagas 2016, section 3.4, step 1). However, I keep getting warnings and errors about non-unique sequence names or illegal characters, despite verifying that the format looks correct.

### Error Messages:

When I run **count.seqs** , I get repeated warnings such as:

```auto
[WARNING]: group M03719_761_000000000-J9GYJ_1_1117_19184_5626 contains illegal characters in the name. Group names should not include :, -, or / characters.
[NOTE]: Updating M03719_761_000000000-J9GYJ_1_1117_19184_5626 to M03719_761_000000000_J9GYJ_1_1117_19184_5626 to avoid downstream issues.

[ERROR]: M03719_761_000000000-J9GYJ_1_1117_19184_5626 is not in your groupfile, please correct.

```

The key issue seems to revolve around Mothur not recognizing the sequence names, despite them being present in both the **names** and **group** files. I’ve checked manually by searching for the names, and they do match in both files. Still, Mothur sees them as different.

Additionally, I frequently get warnings like this during **screen.seqs** :

```auto
[WARNING]: Your groupfile contains more than 1 sequence named 4,1. Sequence names must be unique. Please correct.

```

I’m not sure why these errors persist, as I’ve generated the group file using **make.groups** , and it should contain unique entries.

What I Have Tried:

1. **Manually Reviewing Files** : I have manually reviewed the group and name files to ensure that there are no visible formatting issues, such as unwanted characters or duplicated names.
2. **Cleaning Group Names** : We attempted to replace characters that Mothur finds problematic (such as “-”, “:”, or “/”) using both Mothur’s own handling and custom Python scripts. However, the issue still persists.
3. **Using get.seqs** : I tried using **get.seqs** to match names and groups to ensure consistency, but the problem continued.
4. **Count Table** : I’ve attempted to generate a count table manually but ran into the same sequence recognition issues. Mothur continues to show sequence names as non-unique or not present, even though they are clearly in the files.

Could you provide any guidance on what might be causing this problem and how to resolve it? Specifically:

- Are there any hidden formatting issues that could be triggering these errors?
- Is there an alternative way to generate the count table that might avoid these issues?
- Could there be invisible differences between the sequence names that Mothur is detecting?

Thank you so much for your time and assistance. If you need me to add anything please let me know. I appreciate any help you can provide!

---

<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:** [October 22, 2024, 5:19pm UTC](https://forum.mothur.org/t/issue-with-group-files-and-count-seqs-command-in-mothur/22230/2 "2024-10-22T17:19:11Z")

</div>

`M03719_761_000000000-J9GYJ_1_1117_19184_5626` looks like a sequence name, not a group name.

Also, the screen.seqs error indicated you are reading a count file as a fasta file.

Can you post the make.groups, count.seqs and screen.seqs commands you ran?

Can you post the first 10 lines of the group file you are using?

---

<div class="post-metadata">

**Author:** ![JJOJ](https://avatars.discourse-cdn.com/v4/letter/j/c37758/32.png) [@JJOJ](https://forum.mothur.org/u/JJOJ)\
**Post date:** [October 29, 2024, 8:20pm UTC](https://forum.mothur.org/t/issue-with-group-files-and-count-seqs-command-in-mothur/22230/3 "2024-10-29T20:20:37Z")

</div>

Hi thanks for answering and your reply, but I think I’m not going to be using group.seqs for my analysis. My sequences aren’t very formatted for this. Managed to skip it and do cleaning with screen.seqs, unique.seqs and filter.seqs with no problem.

---

<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:** [November 8, 2024, 8:20pm UTC](https://forum.mothur.org/t/issue-with-group-files-and-count-seqs-command-in-mothur/22230/4 "2024-11-08T20:20:46Z")

</div>

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