uco {seqinr} | R Documentation |
uco
calculates some codon usage index: the codon count eff
, the absolute frequencies freq
or the Relative Synonymous Codon Usage rscu
.
uco( seq, frame = 0, index = c("eff","freq","rscu"), as.data.frame = FALSE)
seq |
a vector of chars |
frame |
an integer (0,1,2) giving the frame |
index |
One of this value |
as.data.frame |
logical. If TRUE : The eff, freq and rscu index will be returned in a data frame. |
If as.data.frame
is TRUE uco
returns a data frame with five columns:
aa |
a vector containing the name of amino-acid |
codon |
a vector containing the corresponding codon |
eff |
a numeric vector containing effectifs of codons |
freq |
a numeric vector containing frequencies of codons |
rscu |
a numeric vector containing the relative synonymous codon usage |
eff |
a factor containing effectifs of codons |
freq |
a factor containing frequencies of codons |
rscu |
a factor containing the relative synonymous codon usage |
D. Charif
To have an overview of the seqinR's functionnality, please consult this vignette:
Charif, D., Lobry, J.R. (2005) SeqinR: a contributed package to the R project for statistical
computing devoted to biological sequences retrieval and analysis. Springer Verlag, Biological and Medical Physics/Biomedical Series, in preparation.
s = read.fasta(File=system.file("sequences/malM.fasta",package = "seqinr")) uco( s[[1]], index="freq") uco( s[[1]], index="eff") uco( s[[1]], index="rscu") uco( s[[1]], as.data.frame = TRUE)