# Format data for Lefse step error

**URL:** <https://forum.biobakery.org/t/format-data-for-lefse-step-error/5958>\
**Category:** LEfSe\
**Created:** [September 22, 2023, 3:14am UTC](https://forum.biobakery.org/t/format-data-for-lefse-step-error/5958 "2023-09-22T03:14:43Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![vasilisazvyagina](https://avatars.discourse-cdn.com/v4/letter/v/ecccb3/32.png) [@vasilisazvyagina](https://forum.biobakery.org/u/vasilisazvyagina)\
**Post date:** [September 22, 2023, 3:14am UTC](https://forum.biobakery.org/t/format-data-for-lefse-step-error/5958/1 "2023-09-22T03:14:43Z")

</div>

Hi there,

I am currently trying to analyse my microbiome data using Lefse. Uploading data went fine, but I keep getting the following error message for the output file of the ‘format data for Lefse’ step:

Traceback (most recent call last): File “/usr/bin/lefse\_format\_input.py”, line 8, in sys.exit(format\_input()) File “/usr/lib/python3.6/site-packages/lefse/lefse\_format\_input.py”, line 437, in format\_input class\_sl,subclass\_sl,class\_h

Could someone please help me with this?

Kind regards,  
Vasilisa

---

<div class="post-metadata">

**Author:** ![vasilisazvyagina](https://avatars.discourse-cdn.com/v4/letter/v/ecccb3/32.png) [@vasilisazvyagina](https://forum.biobakery.org/u/vasilisazvyagina)\
**Post date:** [September 25, 2023, 12:23am UTC](https://forum.biobakery.org/t/format-data-for-lefse-step-error/5958/2 "2023-09-25T00:23:48Z")

</div>

This was my input file:  
[Vasilisa lefse male 5 wks.txt](https://forum.biobakery.org/uploads/short-url/7DKwivlIsoAlalVC2aEgqfcjJpi.txt) (45.6 KB)

---

<div class="post-metadata">

**Author:** ![ddurgan](https://avatars.discourse-cdn.com/v4/letter/d/85f322/32.png) [@ddurgan](https://forum.biobakery.org/u/ddurgan)\
**Post date:** [October 3, 2023, 8:54pm UTC](https://forum.biobakery.org/t/format-data-for-lefse-step-error/5958/3 "2023-10-03T20:54:58Z")

</div>

I’m having the same issue. Did you figure out a solution?

---

<div class="post-metadata">

**Author:** ![vasilisazvyagina](https://avatars.discourse-cdn.com/v4/letter/v/ecccb3/32.png) [@vasilisazvyagina](https://forum.biobakery.org/u/vasilisazvyagina)\
**Post date:** [October 3, 2023, 11:43pm UTC](https://forum.biobakery.org/t/format-data-for-lefse-step-error/5958/4 "2023-10-03T23:43:52Z")

</div>

Hi ddurgan,

I think after the server maintenance, Lefse now requires you to have a Subclass and Subject in order to work. As our analysis didn’t require either of these, my supervisor and I fixed this issue by adding two empty columns in our input file after the Group column: Subclass and Subject.

Please find my input file that worked attached:  
[Vasilisa lefse male 5 wks.txt](https://forum.biobakery.org/uploads/short-url/wA7em4qQ64JWBYEiRyF4C3kmOvD.txt) (45.7 KB)

Hope this helps!

Kind regards,  
Vasilisa
