TickingClock1992 / RIdeogram

154 stars 23 forks source link

How to display a specific area with bars #20

Open kazuaki0816 opened 3 years ago

kazuaki0816 commented 3 years ago

Hi Developer,

I want to display a specific area with a bar. For example, I want to display the coordinates such as the position of repeat and the position of heterochromatin with a bar on the chromosome diagram.

In other words, I want to plot information like # 2 with a bar against information on chromosomes like # 1. Does your tool make this possible?

1

Chr Start End 1 0 187018787 2 0 158822865 3 0 134443407 4 0 125483849 5 0 124558973

2

Chr Start End 1 112636 112700 1 519847 519940 1 635196 635250 1 741262 741317 1 815333 815417 1 1228350 1228404 1 129134729 129134800 1 129842726 129842850 1 129886838 129886900 1 130945692 130945749 1 131086596 131086650 1 131671866 131671938

Best regards,

ASLeonard commented 3 years ago

It isn't perfect, but you can do this using the gene_density example on the cran page. You just need to put some constant value in, or multiple if wanting multiple coloured bands. The only downside is you get a colorbar legend rather than something more appropriate, but that can be fixed by editing the svg.

#>   Chr   Start     End Value
#> 1   1       1 1000000    65