opencobra / memote

memote – the genome-scale metabolic model test suite
https://memote.readthedocs.io/
Apache License 2.0
128 stars 28 forks source link

how to extract total score #687

Closed jotech closed 4 years ago

jotech commented 4 years ago

I would like to use memote in a pipeline and wondering how to extract summary report values?

memote report snapshot returns a html with javascript which is hard to further process without browser. And memote run puts results in a json file which doesn't seem to contain summary values such as the total score.

Is there a way to export the full report as plain text file or a command parameter to return certain summary values?

Midnighter commented 4 years ago

Hi,

At the moment this is not possible via a command line argument. For the memote paper itself, we have extracted all of the tested model results into a table. Take a look at the transform function in the analysis code of the paper.

Could you say what kind of pipeline you are building? I'm very curious to know and may be able to suggest better approaches.

jotech commented 4 years ago

Hi @Midnighter thanks for your reply! I was experimenting a bit last week and came up with rather a simple workaround because I already had run the analysis with memote. I simply used selenium to open the html files and extract the corresponding scores. Sure, not the cleverest solution but it worked out quite nicely!

My background application is that a have a bunch of models created with different metabolic reconstruction methods which I want to compare.

Midnighter commented 4 years ago

I see. Parsing the report definitely seems like a detour but I'm glad you got what you needed. In future, you should definitely be able to store all the different results in one directory and run the analysis code from the supplementary material on that directory.

I'm glad you're using memote to compare outcomes from different pipelines. It's a perfect application. I would urge you to not only look at the total score, though. Also many unscored tests are very relevant.

jotech commented 4 years ago

that's a good point, thanks for your advice!