This is a test version of Biostars. For the public version, visit https://www.biostars.org.
Find the nearest 10 peaks for specific gene using GRanges

Hi, I have two genomic range objects, one of them is gene genomic range which has 56925 genes and the other one is atac genomic ranges, which has 562709 peaks.

For each gene (56925 genes), I need to find 10 nearest peaks based on the location but using distance() function in GenomicRanges library gives not satisfying result, and nearest() method gives only the closest peak so I wonder if there is a straightforward way to find it.

r rna-seq gene atac

0 answers

No answers yet.

Log in to answer this question.