Learn R Programming

seqinr (version 3.1-2)

EXP: Vectors of coefficients to compute linear forms.

Description

This dataset is used to compute linear forms on codon frequencies: if codfreq is a vector of codon frequencies then drop(freq %*% EXP$CG3) will return for instance the G+C content in third codon positions. Base order is the lexical order: a, c, g, t (or u).

Usage

data(EXP)

Arguments

source

ANALSEQ EXPFILEs for command EXP. http://biomserv.univ-lyon1.fr/doclogi/docanals/manuel.html

Details

It's better to work directly at the amino-acid level when computing linear forms on amino-acid frequencies so as to have a single coefficient vector. For instance EXP$KD to compute the Kyte and Doolittle hydrophaty index from codon frequencies is valid only for the standard genetic code. An alternative for drop(freq %*% EXP$CG3) is sum( freq * EXP$CG3 ), but this is less efficient in terms of CPU time. The advantage of the latter, however, is that thanks to recycling rules you can use either sum( freq * EXP$A ) or sum( freq * EXP$A3 ). To do the same with the %*% operator you have to explicit the recycling rule as in drop( freq %*% rep(EXP$A, 16)).

References

citation("seqinr") [object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object]

Examples

Run this code
data(EXP)

Run the code above in your browser using DataLab