tanghaibao / jcvi

Python library to facilitate genome assembly, annotation, and comparative genomics
BSD 2-Clause "Simplified" License
761 stars 186 forks source link

Resources for macrosynteny plot customisation #500

Open mrmrwinter opened 2 years ago

mrmrwinter commented 2 years ago

hi @tanghaibao,

Do you know of any resources or wikis to assist in the aesthetic customisation of the macrosynteny plots? Or is there a common language of commands i can use alongside jcvi.graphics.karyotype?

Many thanks

Mike

aersoares81 commented 2 years ago

I'd love that too!

tanghaibao commented 2 years ago

@mrmrwinter

Good questions. Currently this is mostly customized via command line options in jcvi.graphics.karyotype. There are certain settings in the code that are not fully exposed through options or the layout file. So this is certainly not as flexible.

Are there specific things that are in mind, or is this more of a broader request? Feel free to create issues or PRs.

mrmrwinter commented 2 years ago

Specifically, a few things jump to mind.

Custom colouring of chromosomes (at the track, chromosome, and within chromosome level). This would enable me to show distinct regions within a single chromosome.

Another great addition would be more control over the colouring of blocks/links etc. The current method works ok, but it would be great if we could assign a colour to a chromosome so that all links associated with it are coloured the same way.

Overall, just having more customisation would be great, but ideally it would use a common plotting language (matplotlib/seaborn, etc) so that we can manipulate it how we see fit.

An alternative to this would be an output option that contains anchor or block information as a .bed file, that could then be plotted externally with one of the aforementioned things.

tanghaibao commented 2 years ago

@mrmrwinter

All excellent points - it might take a while before I can come up with ways to address these - so please feel free to create a branch and experiment - I'll help with merging back.

I'll label this issue for follow up.