yatisht / usher

Ultrafast Sample Placement on Existing Trees
MIT License
122 stars 41 forks source link

TSV summary of sequences and placements output #270

Closed abulenciamiguel closed 2 years ago

abulenciamiguel commented 2 years ago

Hello.

I would like to ask if there is a tutorial on how to get the equivalent of tsv output from the web version in CLI.

I've run the usher in conda and got parsimony-scores.tsv and a blank placement_stats.tsv.

Thank you.

AngieHinrichs commented 2 years ago

Hello @ufuomababatunde -- there is not a direct analog of the web interface .tsv from the CLI, but there may be a way to extract the same info using matUtils and some post-processing. Which columns of the web version .tsv do you require? Do you need those for a subset of sequences in the tree, or for all sequences in the tree?

abulenciamiguel commented 2 years ago

Thank you for your response, @AngieHinrichs. I just need the Pango lineage, #Maximally parsimonious placements, and Parsimony score of the new samples that I placed on the global tree.

AngieHinrichs commented 2 years ago

OK, the pango lineages are in the third column of the usher output file clades.txt. The #Maximally parsimonious placements is the third column of placement_stats.tsv and Parsimony score is the second column of placement_stats.tsv.

However, the placement_stats.tsv file is empty if the --write-parsimony-scores-per-node (-p) option is used. That option is for printing the parsimony score of adding a sample at every node in the tree (most of which are not the optimal node!). If you are not using that option, but are still getting an empty placement_stats.tsv file, then please send the usher command line that you are running.

abulenciamiguel commented 2 years ago

Oh, I used the -p parameter. I'll try running usher again using your suggestion.

Thank you very much. :)

Edit: Got the results @AngieHinrichs Thank you very much.