Signac (version 0.2.4)

ClosestFeature: Closest Feature

Description

Find the closest feature to a given set of genomic regions

Usage

ClosestFeature(regions, annotation, ...)

Arguments

regions

A set of genomic regions to query

annotation

Annotation information. Can be a GRanges object or an EnsDb object. If an EnsDb object is provided, protein-coding genes will be extracted from the object and only the closest protein coding genes are reported. If a GRanges object is provided, no filtering is performed and the closest genomic range is reported.

...

Additional arguments passed to StringToGRanges

Value

Returns a dataframe with the name of each region, the closest feature in the annotation, and the distance to the feature.

Examples

Run this code
# NOT RUN {
ClosestFeature(
  regions = head(rownames(atac_small)),
  annotation = StringToGRanges(head(rownames(atac_small)), sep = c(':', '-')),
  sep = c(":", "-")
)
# }

Run the code above in your browser using DataCamp Workspace