codonSumsPerGroup {ORFik} | R Documentation

## Get read hits per codon

### Description

Helper for entropy function, normally not used directly Seperate each group into tuples (abstract codons) Gives sum for each tuple within each group

### Usage

    codonSumsPerGroup(grl, reads, weight = "score", is.sorted = FALSE)

### Arguments

`grl` | a `GRangesList` of 5' utrs, CDS, transcripts, etc.
`reads` | a `GAlignments` or `GRanges` object of RiboSeq, RnaSeq etc. Weigths for scoring is default the 'score' column in 'reads'
`weight` | (default: 'score'), if defined a character name of valid meta column in subject. GRanges("chr1", 1, "+", score = 5), would mean score column tells that this alignment region was found 5 times. ORFik ofst, bedoc and .bedo files contains a score column like this. As do CAGEr CAGE files and many other package formats. You can also assign a score column manually.
`is.sorted` | logical (FALSE), is grl sorted. That is + strand groups in increasing ranges (1,2,3), and - strand groups in decreasing ranges (3,2,1)

### Details

Example: counts c(1,0,0,1), with reg_len = 2, gives c(1,0) and c(0,1), these are summed and returned as data.table 10 bases, will give 3 codons, 1 base codons does not exist.

### Value

a data.table with codon sums

[Package ORFik version 1.12.13 Index]