union-loops-loops-method: Combine two loops objects

Description Usage Arguments Details Value Examples

Description

union combines two loops objects' interactions and anchors and populates the colData matrix where available

Usage

1
2
## S4 method for signature 'loops,loops'
union(x, y)

Arguments

x

A loops object

y

A loops object

Details

This function returns a single loops object that has all the anchors and interactions contained in the two loops objects that were part of the input. However, when the two objects have different samples, the counts matrix will contain missing values (e.g. when loop counts in x are not in y, those values are unknown). While the number of interactions, colData, and anchors should be correct, we need to correct the counts using a subsetting function. The row data gets re-initialized here to only the loop widths

Value

A loops obect

Examples

1
2
3
4
5
6
7
8
# divide and recombine samples
rda<-paste(system.file('rda',package='diffloop'),'loops.small.rda',sep='/')
load(rda)
naive <- loops.small[,1:2]
primed <- loops.small[,3:4]
np <- union(naive, primed)
# Subset from full to get correct counts
c.np <- loopsSubset(np, loops.small)

diffloop documentation built on Nov. 8, 2020, 5:48 p.m.