| longestORFs {ORFik} | R Documentation |
Rule: if seqname, strand and stop site is equal, take longest one. Else keep. If IRangesList or IRanges, seqnames are groups, if GRanges or GRangesList seqnames are the seqlevels (e.g. chromosomes/transcripts)
longestORFs(grl)
grl |
a |
a GRangesList/IRangesList, GRanges/IRanges
(same as input)
Other ORFHelpers:
defineTrailer(),
mapToGRanges(),
orfID(),
startCodons(),
startSites(),
stopCodons(),
stopSites(),
txNames(),
uniqueGroups(),
uniqueOrder()
ORF1 = GRanges("1", IRanges(10,21), "+")
ORF2 = GRanges("1", IRanges(1,21), "+") # <- longest
grl <- GRangesList(ORF1 = ORF1, ORF2 = ORF2)
longestORFs(grl) # get only longest