Skip to contents

This function creates a continuous scale for a specific chromosome region. It sets the limits to the start and end positions of the region and formats the axis labels in a genomic coordinate style.

Usage

scale_x_genome_region(region, ...)

Arguments

region

A string specifying a genomic region (e.g., "chr1:1000000-2000000") or a GRanges object

...

Additional arguments passed to scale_x_genome

Value

A ggplot2 scale object

Examples

if (FALSE) { # \dontrun{
library(ggplot2)
p <- ggplot(data, aes(x = start)) + geom_point() +
     scale_x_genome_region("chr1:1000000-2000000")
} # }