Learn R Programming

vhcub (version 1.0.0)

PR2.plot: Parity rule 2 (PR2) plot

Description

Make a Parity rule 2 (PR2) plot, where the AT-bias [A3/(A3 +T3)] at the third codon position of the four-codon amino acids of entire genes is the ordinate and the GC-bias [G3/(G3 +C3)] is the abscissa. The center of the plot, where both coordinates are 0.5, is where A = U and G = C (PR2), with no bias between the influence of the mutation and selection rates.

Usage

PR2.plot(fasta.df)

Arguments

fasta.df

a data frame with seq_name and its DNA sequence.

Value

A ggplot object.

Details

For more information about PR2 plot Butt et al., 2016.

Examples

Run this code
# NOT RUN {
# read DNA from fasta file
fasta <- fasta.read("virus.fasta", "host.fasta")
fasta.v <- fasta[[1]]
fasta.h <- fasta[[2]]
# }
# NOT RUN {
PR2.plot(fasta.v)

# }

Run the code above in your browser using DataLab