bnprks / BPCells

Scaling Single Cell Analysis to Millions of Cells
https://bnprks.github.io/BPCells
Other
166 stars 17 forks source link

[r] fix trackplot bugs with small tracks/motifs #115

Closed immanuelazn closed 3 months ago

immanuelazn commented 3 months ago

Description

Various small changes to coverage plots and genome peak plots to handle smaller motifs better.

Tests

immanuelazn commented 3 months ago

For peaks with no arrows: Before

image

After

image

Code to run:


region <- GenomicRanges::GRanges(
  seqnames = S4Vectors::Rle(c("chr15")),
  ranges = IRanges::IRanges(52789700:52790000)
)
trackplot_genome_annotation(
  loci=demo_small_motifs$hits$Eye_c11,
  region=region,
  annotation_size=3,
  show_strand=TRUE,
  color_by="score",
  label_by="name",
  num_arrows=50
)