I have set of compressedList in the multiple list where each compressedList are corresponds to overlap position index of one set of genomic interval to another, and the order of compressedList in each list are very different. However, I am trying to integrate these multiple compressedList into one without duplication. To make things clarify, this data are the result of finding overlap region between two GRanges object, where queryLength and subjectLength are different. FYI, all data and output are simulated to ease readability of post. Does anyone know any trick of doing this sort of manipulation? I expect my desired output as compressedList of each list element in the final list. Is that possible to integrate them easily/efficiently?
Things are bit of different when I integrating more than two symmetric
findOverlaps() for multiple GRanges, where order of GRanges object in function are really matters. I just want to figure out any solution how I can get my expected output if all Hit objects in the IntegerList. Any possible idea, approach are highly appreciated.
# mini example to run (simulated)
v1 <- list( a=IntegerList(1,2,3), b=IntegerList(3,3,4)) v2 <- list( b=IntegerList(1,2,3,4), a=IntegerList(integer(0),1,2,3))
# desired output:
I am trying to integrate v1, v2 into one list with specific order (i.e,
my_output <- list(a=IntegerList(), b=IntegerList())) where each list element must comply with compressedList object, for example, this is my expected output (manually generated):
> desired_output [] IntegerList of length 5 [] 0 [] 1 [] 1 [] 2 [] 3 [] IntegerList of length 5 [] 1 [] 2 [] 3 [] 3 [] 4
How can I get my expected output easily/efficiently ? Can anyone propose possible ideas to solve my problem? Thanks a lot.