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

Indicate duplication event on synteny plot? #740

Open
erika-r-moore opened this issue Jan 9, 2025 · 1 comment
Open

Indicate duplication event on synteny plot? #740

erika-r-moore opened this issue Jan 9, 2025 · 1 comment

Comments

@erika-r-moore
Copy link

Hello!

I am wanting to show a triplication event between different species in a synteny plot, similar to the figure posted in #642. The gene depth ratio between my two species are 1:3, so I believe that means there has been a triplication event. Also, I believe I can see a triplication event within my plot:
image

Given this, how can I pinpoint which genes are triplicated and highlight only them in my synteny plot?

Some code that may be relevant:

python -m jcvi.compara.catalog ortholog sp1 sp2 --no_strip_names
python -m jcvi.compara.synteny depth --histogram sp1.sp2.lifted.anchors

image

Also, I tried to do the blocks and microsynteny, but it did not work out:

python -m jcvi.compara.synteny mcscan sp1.bed sp1.sp2.lifted.anchors --iter=3 -o sp1.sp2.i3.blocks
python -m jcvi.formats.bed merge sp1.bed sp2.bed -o sp1.sp2.bed
python -m jcvi.graphics.synteny sp1.sp2.i3.blocks sp1.sp2.bed blocks.layout

blocks.layout:

# x,   y, rotation,   ha,     va,   color, ratio,            label
0.5,	0.6,	0,	center,	top,	m,	1,	sp1
0.1,	0.2,	0,	center,	bottom,	#fc8d62,	.3,	sp2
0.5,	0.2,	0,	center,	bottom,	#fc8d62,	.3,	sp2
0.9,	0.2,	0,	center,	bottom,	#fc8d62,	.3,	Acicarpha
# edges
e,	0,	1
e,	1,	2
e,	2,	3

I am happy to provide more information, I am just unsure what you would need to help with this.

Thanks,
Erika

@tanghaibao
Copy link
Owner

tanghaibao commented Jan 19, 2025

@erika-r-moore

The highlights in #642 were manual highlights. There is no automated way as far as I know.

My recommended path is to identify (e.g. in EXCEL) a region that visually match 3 regions in sp1.sp2.i3.blocks and then look for the same sp1 region in sp1.sp2.anchors.simple.

You can then add the highlight in front of those blocks, as suggested in the wiki.

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