Skip to contents

The enrichment of every k-mer at the observed cut sites over its frequency in the accessible genome. The k-mer is centred on the cut and the weights are symmetrised over the two strands, because both fragment ends are counted as insertions.

Usage

computeKmerBias(
  ins,
  regions,
  genome,
  k = 6L,
  max.ins = 2e+06,
  chunk = 1e+05,
  bg = NULL
)

Arguments

ins

A GRanges of insertion sites with a score column.

regions

A GRanges of the accessible regions.

genome

A BSgenome object.

k

Length of the k-mer.

max.ins

Number of insertion sites drawn for the estimate.

chunk

Number of sites read from the genome at a time.

bg

Background counts from kmerBackground, or NULL to count them here.

Value

A named numeric vector of k-mer weights.

Examples

if (FALSE) { # \dontrun{
bias <- computeKmerBias(ins, peaks, Hsapiens, bg = bg)
} # }