# Lefse input problem resulting in error "IndexError: list index out of range"

**URL:** <https://help.galaxyproject.org/t/lefse-input-problem-resulting-in-error-indexerror-list-index-out-of-range/6512>\
**Category:** Uncategorized\
**Tags:** lefse, galaxy-biobakery, usinggalaxy\
**Created:** [August 15, 2021, 3:32pm UTC](https://help.galaxyproject.org/t/lefse-input-problem-resulting-in-error-indexerror-list-index-out-of-range/6512 "2021-08-15T15:32:12Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![Emma](https://avatars.discourse-cdn.com/v4/letter/e/57b2e6/32.png) [@Emma](https://help.galaxyproject.org/u/Emma)\
**Post date:** [August 15, 2021, 3:32pm UTC](https://help.galaxyproject.org/t/lefse-input-problem-resulting-in-error-indexerror-list-index-out-of-range/6512/1 "2021-08-15T15:32:12Z")

</div>

I am so sorry to bother you to help me solve this problem. I wanna do the Lefse analysis, the first step of format data seems failed . I can’t get the point about the error. I would be so appreciated if this will be solved. Thx!!  
Details:  
Traceback (most recent call last):  
File “/shed\_tools/testtoolshed.g2.bx.psu.edu/repos/george-weingart/lefse/a6284ef17bf3/lefse/format\_input.py”, line 429, in   
class\_sl,subclass\_sl,class\_hierarchy = get\_class\_slices(zip(\*cls.values()))  
File “/shed\_tools/testtoolshed.g2.bx.psu.edu/repos/george-weingart/lefse/a6284ef17bf3/lefse/format\_input.py”, line 145, in get\_class\_slices  
previous\_class = data[0][0]  
IndexError: list index out of range

---

<div class="post-metadata">

**Author:** ![jennaj](https://sea2.discourse-cdn.com/flex020/user_avatar/help.galaxyproject.org/jennaj/32/27_2.png) [@jennaj](https://help.galaxyproject.org/u/jennaj)\
**Post date:** [August 16, 2021, 11:30pm UTC](https://help.galaxyproject.org/t/lefse-input-problem-resulting-in-error-indexerror-list-index-out-of-range/6512/2 "2021-08-16T23:30:49Z")

</div>

Hi @Emma

> [@LEfSs uploded file looks different to 2018 – problem?](https://help.galaxyproject.org/t/lefss-uploded-file-looks-different-to-2018-problem/4867/2):
>
> You are working at this public server, correct? [Galaxy | Hutlab Galaxy](https://huttenhower.sph.harvard.edu/galaxy/)
> 
> The server is set up a bit differently than other public servers and hosts custom versions of tools, in particular the `Lefse` tool suite. Their support/admin team does not follow this forum, but there are other ways to contact them about odd or non-reproducible results.

That said, this error in technical terms means that the tool is looking for specific data in part of the input that isn’t being found. There is probably some problem with the column or row selected for the option “Select which [row|column] to use as subclass”.

Try double-checking your tabular input (first option on the tool’s form) to make sure there is content in the row or column you selected. Tutorials and example data are hosted on that public Galaxy server for comparison. Scoll down on that tool form for an example of input data organized by rows.

Hope that helps!

---

<div class="post-metadata">

**Author:** ![Emma](https://avatars.discourse-cdn.com/v4/letter/e/57b2e6/32.png) [@Emma](https://help.galaxyproject.org/u/Emma)\
**Post date:** [September 11, 2021, 3:45am UTC](https://help.galaxyproject.org/t/lefse-input-problem-resulting-in-error-indexerror-list-index-out-of-range/6512/3 "2021-09-11T03:45:54Z")

</div>

Really THX！I have solved this problem by using the method you mentioned above.

---

<div class="post-metadata">

**Author:** ![jennaj](https://sea2.discourse-cdn.com/flex020/user_avatar/help.galaxyproject.org/jennaj/32/27_2.png) [@jennaj](https://help.galaxyproject.org/u/jennaj)\
**Post date:** [January 16, 2025, 6:13pm UTC](https://help.galaxyproject.org/t/lefse-input-problem-resulting-in-error-indexerror-list-index-out-of-range/6512/4 "2025-01-16T18:13:55Z")

</div>


