Skip to content
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

Circular DNA feature wrap issue #29

Open
mmcguffi opened this issue Feb 10, 2020 · 2 comments
Open

Circular DNA feature wrap issue #29

mmcguffi opened this issue Feb 10, 2020 · 2 comments

Comments

@mmcguffi
Copy link

mmcguffi commented Feb 10, 2020

image

Hello, I have found that when I try to render a circular graphic record that has a feature that spans the "origin", it is instead incorrectly rendered as looping around the entire DNA segment. I see that this does not happen in your bioRxiv preprint, so maybe I am missing something obvious?

This is the raw text from the .gbk for the incorrect feature in question in the picture above:

enhancer        join(7368..7381,1..366)
                     /label="CMV enhancer (2)"
                     /identity="100.0"
                     /match length="100.0"
                     /Other:="enhancer"
@Zulko
Copy link
Member

Zulko commented Feb 10, 2020

I think we never had an origin-spanning feature plotted circularly before (in the preprint figure, there are no origin-spanning annotations but the Graphic Record itself is rotated with graphic_record.rotate() which is why some features appear to be cross-origin).

That seems fixable (by amending the way the angles of the arrow are computed here) but I am under the water this week and possibly the next, so if you find a fix, I'll happily merge it.

@mmcguffi
Copy link
Author

mmcguffi commented Feb 15, 2020

I took a look at the CircularGraphicRecord.py, but I believe the coordinates that are passed to CircularGraphicRecord from GraphicRecord are already incorrect, thus the error lies within GraphicRecord (GR sends CGR [0, len(sequence)] instead of [1034, 6], or something). These are then translated into [90.0 -270.0] in polar coordinates.

I see you have this function already:

def split_overflowing_features_circularly(self):

There is a lot to follow in this code (hence I haven't cracked this yet), but I don't think this function is implemented?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants