weight_fxn: Scaled covariance between two peaks

Description Usage Arguments Value Examples

Description

Scaled covariance between two peaks give the distance between them

Usage

1
2
weight_fxn(distance, decay = 0.00016, maxWeight = 0.8,
  windowSize = 5e+06)

Arguments

distance

distance in bp between peaks

decay

parameter

maxWeight

maximum weight when distance is zero

windowSize

width of window in bp around each interval beyond which weight is zero

Value

Return result of exp(-decay*abs(distance)/1000), but scalated so that f(0) = maxWeight and f(windowSize) = 0

Examples

1
2
3
4
5
6
7
decay=1.6e-4
maxWeight = 0.8
windowSize = 5e6

# compute the weight for this distance
weight_fxn(1000, decay, maxWeight, windowSize)
 

GabrielHoffman/pinnacle documentation built on May 3, 2019, 3:02 p.m.