G+C Content {seqinr} | R Documentation |
Calculates the fraction of G+C bases of the input nucleic acid
sequence(s). It reads in nucleic acid sequences, sums the number of
'G' and 'C' bases and writes out the result as the fraction (in the
interval 0.0 to 1.0) of the length of the whole sequence. Global G+C
content GC
, G+C in the first position of the codon bases
GC1
, G+C in the second position of the codon bases
GC2
, and G+C in the third position of the codon bases
GC3
can be computed.
GC(seq) GC1(seq) GC2(seq) GC3(seq)
seq |
any nucleic acid sequence |
GC
returns the fraction of G+C as a numeric vector,
GC1
returns the fraction of G+C at first codon position as a numeric vector,
GC2
returns the fraction of G+C at second codon position as a numeric vector,
GC3
returns the fraction of G+C at third codon position as a numeric vector.
D. Charif and L. Palmeira
citation("seqinr")
s=s2c("agtctggggggccccttttaagtagatagatagctagtcgta") GC(s) GC1(s) GC2(s) GC3(s)