countOvpPACds | R Documentation |
countOvpPACds counts overlapping between PACdatasets.
countOvpPACds(
pacds1,
pacds2,
mode1 = "point",
mode2 = "point",
d = 0,
pats1 = 1,
pats2 = 1
)
pacds1 |
a PACdataset. |
pacds2 |
another PACdataset. |
mode1 |
use coord or UPA_start/UPA_end for pacds1, default is point (using coord). If mode1=region, then use UPA_start/UPA_end. |
mode2 |
same as mode1 except for pacds2. |
d |
distance to count overlapping, default is 0 (no gap between qry and sbj). |
pats1 |
cutoffs to filter pacds1 by total tag number of all samples. If pats1<=1, then do not filter. Multiple cutoffs can be set, like pats1=c(10, 20, 30). |
pats2 |
same as pats1 but to filter pacds2. |
This function is used to compare PA coordinates of two PACdataset objects.
A dataframe with 8 columns: PAT1, PAT2, Total1, Total2, Ovp1, Ovp2, Ovp1Pct, Ovp2Pct. Row number is the combination number of pats1 and pats2.
data(PACds)
pacds1=PACds
pacds2=PACds
pacds2@anno$coord=pacds2@anno$coord+sample(-10:10, 1)
## Count exactly the same positions between two pacds without filtering
countOvpPACds(pacds1, pacds2, d=0)
## count overlapping with different cutoffs
countOvpPACds(pacds1, pacds2, d=50, pats1=1, pats2=seq(0,20,10))
## count overlapping with different cutoffs, comparing ds1's coord ~ ds2's region
countOvpPACds(pacds1, pacds2, mode1='point', mode2='region', d=50, pats1=1, pats2=seq(0,20,10))
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.