fit_background_model: Fit a background model to a selective ribosome profiling data...

Description Usage Arguments Details Value See Also

Description

Reads in sample1 at ribosome positions for which the nascent chain is completely obscured by the ribosome exit tunnel (typically the first 30 codons of a CDS) are assumed to represent background binding. A background distribution is fitted to read counts within the tunnel.

Usage

1
2
3
4
5
6
7
8
fit_background_model(
  data,
  sample1,
  sample2,
  bin,
  tunnelcoords = 18:90,
  use_quantile = 0.5
)

Arguments

data

A serp_data object.

sample1

Name of the first sample (the numerator). If missing, the default sample1 of the data set will be used.

sample2

Name of the second sample (the denominator). If missing, the default sample2 of the data set will be used.

bin

Binning mode (bynuc or byaa). If missing, the default binning level of the data set will be used.

tunnelcoords

Ribosome positions in nucleotites for which it is assumed that the nascent chain is fully obscured by the exit tunnel.

quantile

Only genes whith sample2 >= quantile(sample2, use_quantile) will be used for parameter estimation. This reduces the effect of random drop-outs on the final model.

Details

For each gene, read counts within tunnelcoords are summed up (separately for sample1 and sample2). Counts in sample1 conditioned on sample1 + sample2 are assumed to follow a beta-binomial distribution. Parameter estimation is performed by maximum likelihood separately for each sample and replicate.

Value

A serp_data object.

See Also

get_background_model, test_binding, get_binding_positions, plot_binding_positions


ilia-kats/RiboSeqTools documentation built on Oct. 5, 2020, 7:41 p.m.