Join GitHub today
GitHub is home to over 28 million developers working together to host and review code, manage projects, and build software together.Sign up
strand: XS tag is an aligner specified field and intention can clash (patch included). #473
It appears that the strand function was originally coded against XS
BWA-mem defines XS as 'suboptimal alignment score' which is numeric
I've attempted to preserve original functionallity, however this may
Technically X?, Y?, Z? tags should not be baked into any BAM rendering components, see BAM specification.
Hey I'm sorry I didn't get to review this before the release. it seems like a perfectly fine fix but i just wasn't able to test it (i know i know...should have done that). we're a little short staffed but i really appreciate your input. I would like to continue speeding along with jbrowse development and i'll try and get this included.
Color according to XS is useful if the RNA-seq was performed in a non-stranded manner.
So, I would suggest not to mix strand from XS and from FLAG in a single track with the same color.
The aligner could do other nice stuff based on the construction method and read number information.
The current code
mixes the value of XS and the FLAG.
But surely, you need to check the caller to handle the new return value.
referenced this pull request
Jul 21, 2014
I have been thinking that a configuration variable would be good. I made a demo implementation of how this might look using a track configuration variable called "useXS" that can be applied to a BAM track. Code here: https://github.com/GMOD/jbrowse/tree/xs_config
Screenshot with XS flags for both directions
One concern is that my demo no longer is going to mix the XS and seq_reverse_complemented to compute strand. Another concern is what we should set useXS as by default? I had it set to true on my branch, but I think it should probably be false in practice.
Hi Colin, that looks great. From my perspective I don't think the mixing of XS and flag-strand should be allowed, I only applied it in my original patch in an attempt to preserve existing behaviour. For this reason the default for useXS may want to be true (although as this is actually a non standard field for strand is should technically be false).
Anyways, I have added a new branch with proposals for having both the useXS and useReversedTemplate flags for the color function.