-
Notifications
You must be signed in to change notification settings - Fork 11
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
CSV inputs don't yield results #23
Comments
Hey @acolorado1 , I think it should be able to read .csv files, based on the section of the KO reader function linked here: AMON/AMON/predict_metabolites.py Line 59 in 0764de2
How is your CSV file formatted? AMON assumes that the KOs are column headers. So if your CSV file has KOs as rows (or inside of a column), it will get read incorrectly. I'll run some tests to verify, but that's my first idea - trying to put it out there quick since I know you're on a bit of a time crunch. CSV reading is tested here: AMON/tests/test_predict_metabolites.py Line 56 in 0764de2
The input CSV would need to be formatted as:
The .txt file parser is different from the .csv parser, given that the .txt parser splits based on any whitespace, and the .csv parser is effectively If this is what's going on, we can definitely fix the documentation for that! Also - what is the actual error you're getting from this? It'd be helpful to know what url it's trying to access.
|
Hey @sterrettJD, It appears that I did not correctly format the file then as I gave KOs as rows which is how the txt file appears. Unfortunately, I don't have the full error available but it ended with the Regardless, I have gotten it to run without a problem, but it would be helpful to add example inputs to the README. |
Despite the documentation saying that CSV files are an acceptable input format this is not the case. Two senarios:
-i
and--other_gene_set
) resulted in all compounds and KOs being mapped to the .txt file-i
) resulted in the following error:While I think that this is a relatively easy fix, it certainly took a while to troubleshoot.
What has worked for me are .txt files containing rows with either one compound or KO not surrounded by quotes. For example:
I have not tested the utilization of TSVs but at this point it seems unlikely that it would be an acceptable format. Additionally, all my CSVs had a column name (KO) therefore the removal of the column name might allow CSVs to work. Nevertheless, this should be tested and the documentation updated.
The text was updated successfully, but these errors were encountered: