search for: matchmatrix

Displaying 2 results from an estimated 2 matches for "matchmatrix".

2010 Oct 21
2
How to access values in s4 method
...s as follows: require(IRanges); query <- IRanges(c(1, 4, 9), c(5, 7, 10)) subject <- IRanges(c(2, 2, 10), c(2, 3, 12)) findOverlaps(query, subject) Output of find overlap function is: ------------------ 1> findOverlaps(query, tree) An object of class "RangesMatching" Slot "matchMatrix": query subject [1,] 1 1 [2,] 1 2 [3,] 3 2 Slot "DIM": [1] 4 3 -------------------- How to access the values in the output? [[alternative HTML version deleted]]
2009 Nov 15
4
pairs
Hi, All, I have an n by m matrix with each entry between 1 and 15000. I want to know the frequency of each pair in 1:15000 that occur together in rows. So for example, if the matrix is 2 5 1 6 1 7 8 2 3 7 6 2 9 8 5 7 Pair (2,6) (un-ordered) occurs together in rows 1 and 3. I want to return the value 2 for this pair as well as that for all pairs. Is there a fast way to do this avoiding loops?