veg / hyphy-analyses

HyPhy standalone analyses
MIT License
39 stars 17 forks source link

Label tree not writing the labels #46

Closed rsiani closed 1 year ago

rsiani commented 1 year ago

Hi, I have been experiencing a weird problem with the labelling.

hyphy ~/hyphy-analyses/LabelTrees/label-tree.bf --tree raxml.bestTree --label H --list ../H.list --output H.tree

I checked several times and the label are correct. However I noticed the also running

grep -F -f host.list flhc.raxml.bestTree

does not return any match. So if that is called in the background I am a bit confused as to what is going on. Running grep on single lines correctly return the matches. Any idea what could be the issue? The only thing I am not sure is whether there might be duplicate sequences, but usually alignment tools remove those from the input (so before I construct the three).

Thanks

spond commented 1 year ago

Dear @rsiani,

Could you please share the input files (raxml.bestTree and H.list)? I'll be happy to take a look, otherwise I won't be much help.

Best, Sergei

rsiani commented 1 year ago

Dear @spond, I uploaded the file to gist here: files. Let me know if you can get them, first time sharing via gist.

Bests, Rob

spond commented 1 year ago

Dear @rsiani,

You label file has an extra space at the end of each line so instead of "GCA_000143225_03002" the labeler was looking for "GCA_000143225_03002 ".

I'll add some code to the script to strip out trailing spaces, but simply deleting those from your H.list file should do the trick for now.

Best, Sergei

rsiani commented 1 year ago

Oh, thank you very much. I should have thought of looking for horses but went straight for the zebra...

spond commented 1 year ago

Dear @rsiani,

I am glad you showed me this example! Making a minor scipt adjustment for the next update to deal with trailing spaces will probably save users a few hours of frustration.

Best, Sergei