Hello, There is no convenience function to sample nucleotide positions from a GRanges object. My approach is to generate a GRanges of every chromosomal position with a width of 1, then find the overlaps with the desired ranges (admissible regions), then sample the positions that overlapped. The construction of the GRanges object containing every chromosome position is inefficient, as is finding its overlaps with another GRanges object. Could an optimised function for this task be added to GenomicRanges ?
-------------------------------------- Dario Strbenac PhD Student University of Sydney Camperdown NSW 2050 Australia _______________________________________________ Bioc-devel@r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/bioc-devel