Learn R Programming

diffHic (version 1.4.2)

getDistance: Get the linear distance for each interaction

Description

Compute the distance between interacting regions on the linear genome.

NOTE: This function is deprecated in favour of the pairdist function from the InteractionSet package.

Usage

getDistance(data, type=c("mid", "gap", "span"))

Arguments

data
a DIList object
type
a character string specifying the type of distance to compute

Value

An integer vector is returned containing the distances between interacting regions for each pair in data.

Details

The getDistance function examines each interaction in data$pairs and computes the distance between the corresponding regions on the linear genome. Options to compute the distances are mid, for the distance between the midpoints of the regions; gap, for the distance of the interval lying between the regions (set to zero, if regions are overlapping); and span, for the total distance spanned by the interaction, including both regions. Interchromosomal interactions are marked with NA.

See Also

squareCounts, connectCounts