The bioBakery help forum

LefSe error message on galaxy

Hello everyone,

I and trying to run LefSe analysis on galaxy but keep getting the error message as below:

Traceback (most recent call last):
  File "/shed_tools/testtoolshed.g2.bx.psu.edu/repos/george-weingart/lefse/a6284ef17bf3/lefse/format_input.py", line 435, in <module>
    feats = numerical_values(feats,params['norm_v'])
  File "/shed_tools/testtoolshed.g2.bx.psu.edu/repos/george-weingart/lefse/a6284ef17bf3/lefse/format_input.py", line 174, in numerical_values
    feats[k] = [float(val) for val in v]
ValueError: could not convert string to float: no

I’ve looked at other posts and change the format but still get the same error.
Please find the sample data attached. Any suggestions will be appreciated. Thanks!

test.txt (1.8 KB)

Hi!

I apologize for the delayed response! I looked at your attached data and I believe this issue is the e- in the numbers. If convert everything to just the numbers, I think this could fix the issue. If you try that and it doesn’t work please let me know!

Best,
Kelsey

were you able to get this to work? I’m getting the same error and can’t figure out what I’m doing wrong with my dataset.

I see below someone commented it was the scientific notation, but I can get a sample file to run with scientific notation so I’m not sure that that is the problem (and I’m not using scientific notation in my current data set)

Hi @henganl2 and @AbbiHern,

I only suggested the scientific notation because when I open the file it automatically converted it and I received no errors when taking that test file running it through Galaxy. The caveat to that is I can replicate the error If I do not assign the first three rows as the subject, class, and subclass. For either of you, are you assigning any row with a character in it to those categories in the format stage? If you are, I am unable to replicate this error and would need a minimally reproducible example. The only time we see this error typically is if there is a row of characters or a random cell of characters in the feature table. Apologies I cannot be of more assistance.

Best,
Kelsey

I understand - I appreciate you being helpful!

I think my problem with my current dataset was that there was a metadata column than wasn’t being used (I have 3 factors). When I delete that, I can get it to run.

Thanks for the input!