YuLab-SMU/ggmsa

how to add a group of point in to ggmsa

Opened this issue · 1 comments

Hi,
I am trying to annotate two group specific point in the picture. However, it doesn't seem to work properly . Please see examples below:

p<-ggmsa(aln_data,start = 1,end=400,color = "Chemistry_NT", char_width = 0.5,seq_name = T,border = NA)+facet_msa(50)
pos_info =data.frame('pos'=rep(c(10,20,60,300),2),group =rep(c('HG','GW'),each=4))
p+geom_point(data=pos_info,aes(x=pos,y=3.2,color=group,shape=group),size=0.2)

图片

hope you can give me some advice

Hi, @loverlyday

Maybe you can try using geom_rect for grouping.
Pls see #26

Regards,
Lang